Last change
on this file since b29a1e8 was a2f1ea8d, checked in by caparsons <caparson@…>, 2 years ago |
added test for fixed waituntil break case
|
-
Property mode
set to
100644
|
File size:
463 bytes
|
Line | |
---|
1 | #include <select.hfa>
|
---|
2 | #include <channel.hfa>
|
---|
3 |
|
---|
4 | channel(long long int) A{1}, B{1};
|
---|
5 |
|
---|
6 | int main( int argc, char * argv[] ) {
|
---|
7 | printf("START\n");
|
---|
8 | long long int a, b, c, i = 0, myTotal = 0;
|
---|
9 | insert( A, 23 );
|
---|
10 | insert( B, 4 );
|
---|
11 | for( ;;i++ ) {
|
---|
12 | waituntil( a << A ) { myTotal += a; }
|
---|
13 | and waituntil( b << B ) { printf("BREAK\n"); break; }
|
---|
14 | printf("IF THIS PRINTS THE BREAK ABOVE DOESN'T WORK PROPERLY\n");
|
---|
15 | }
|
---|
16 | printf("DONE\n");
|
---|
17 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.