Changeset cb69fba
- Timestamp:
- May 4, 2023, 2:39:28 PM (19 months ago)
- Branches:
- ADT, ast-experimental, master
- Children:
- a882b68
- Parents:
- ca8c91ce
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
libcfa/src/concurrency/channel.hfa
rca8c91ce rcb69fba 343 343 344 344 static inline bool register_select( chan_read(T) & this, select_node & node ) with(this.chan, this) { 345 // mutex(sout) sout | "register_read";346 345 lock( mutex_lock ); 347 346 node.extra = &ret; // set .extra so that if it == 0p later in on_selected it is due to channel close … … 416 415 417 416 static inline bool register_select( chan_write(T) & this, select_node & node ) with(this.chan, this) { 418 // mutex(sout) sout | "register_write";419 417 lock( mutex_lock ); 420 418 node.extra = &elem; // set .extra so that if it == 0p later in on_selected it is due to channel close … … 441 439 // handle blocked consumer case via handoff (buffer is implicitly empty) 442 440 ConsEmpty: if ( !cons`isEmpty ) { 443 if ( !__handle_waituntil_OR( cons ) ) { 444 // mutex(sout) sout | "empty"; 445 break ConsEmpty; 446 } 447 // mutex(sout) sout | "signal"; 441 if ( !__handle_waituntil_OR( cons ) ) break ConsEmpty; 448 442 __cons_handoff( chan, elem ); 449 443 __set_avail_then_unlock( node, mutex_lock );
Note: See TracChangeset
for help on using the changeset viewer.