source:
tests/enum_tests/input.cfa
@
1571e4d
Last change on this file since 1571e4d was 1ad112a5, checked in by , 4 months ago | |
---|---|
|
|
File size: 318 bytes |
Rev | Line | |
---|---|---|
[1842167] | 1 | #include <fstream.hfa> |
2 | #include <enum.hfa> | |
3 | ||
4 | int main() { | |
[1ad112a5] | 5 | enum(int ) E { BBB = 3, AAA, AA, AB, B, CB, AC }; |
[1842167] | 6 | E e; |
7 | ||
8 | for () { | |
9 | try { | |
10 | sin | e; | |
11 | } catch( missing_data * ) { | |
12 | sout | "missing data"; | |
13 | continue; // try again | |
14 | } // try | |
15 | if ( eof( sin ) ) break; | |
[1ad112a5] | 16 | sout | e | "= " | value( e ); |
[1842167] | 17 | } // for |
18 | } |
Note: See TracBrowser
for help on using the repository browser.