Changes in / [c16cc99:d829c6d]
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
tests/exceptions/pingpong_nonlocal.cfa
rc16cc99 rd829c6d 3 3 #include <fstream.hfa> 4 4 #include <mutex_stmt.hfa> 5 #include <locks.hfa> 5 6 6 7 exception num_ping_pongs { int num; }; … … 14 15 }; 15 16 17 semaphore sync{0}; 18 16 19 void ?{}( Ping_Pong & this, char * name ) with( this ) { 17 20 this.name = name; … … 20 23 } 21 24 25 int numtimes = 100; 26 22 27 void main( Ping_Pong & this ) with( this ) { 23 enum { numtimes = 100 };24 25 28 void inc_resume_at( int value ) { 26 29 except.num = value + 1; 27 30 resumeAt( partner, except ); 28 31 } 32 // mutex( sout ) sout | name | "start"; // removed to get rid of output race 29 33 try { 30 34 for () { … … 41 45 } 42 46 } 47 // mutex( sout ) sout | name | "end"; // removed to get rid of output race 43 48 } 44 49
Note: See TracChangeset
for help on using the changeset viewer.