Ignore:
Timestamp:
Mar 19, 2025, 4:54:09 PM (10 months ago)
Author:
Peter A. Buhr <pabuhr@…>
Branches:
master
Children:
5329cba
Parents:
42cd67b8 (diff), e1358c0 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Merge branch 'master' of plg.uwaterloo.ca:software/cfa/cfa-cc

File:
1 edited

Legend:

Unmodified
Added
Removed
  • tests/concurrency/waituntil/timeout.cfa

    r42cd67b8 rfd3be42  
    66
    77int main() {
    8     waituntil( sleep( 1`ms ) ) { printf("timeout\n"); }
    9     waituntil( timeout( 1`s ) ) { printf("timeout\n"); } or waituntil( timeout( 2`s ) ) { printf("timeout\n"); }
    10     waituntil( timeout( 100`s ) ) { printf("timeout 1\n"); } or else { printf("else\n"); }
    11     waituntil( timeout( 1`ns ) ) { printf("timeout\n"); } and waituntil( timeout( 2`s ) ) { printf("timeout\n"); }
     8    waituntil( _timeout( 1`ms ) ) { printf("timeout\n"); }
     9    waituntil( _timeout( 1`s ) ) { printf("timeout\n"); } or waituntil( _timeout( 2`s ) ) { printf("timeout\n"); }
     10    waituntil( _timeout( 100`s ) ) { printf("timeout 1\n"); } or else { printf("else\n"); }
     11    waituntil( _timeout( 1`ns ) ) { printf("timeout\n"); } and waituntil( _timeout( 2`s ) ) { printf("timeout\n"); }
    1212    int count = 0;
    1313    for ( i; 1000 )
    14         waituntil( timeout( 1`ns ) ) { count++; } or else { count++; }
     14        waituntil( _timeout( 1`ns ) ) { count++; } or else { count++; }
    1515
    1616    assert( count == 1000 );
    17     sleep( 1`ms );
     17    _timeout( 1`ms );
    1818    printf("done\n");
    1919}
Note: See TracChangeset for help on using the changeset viewer.