Ignore:
Timestamp:
Mar 29, 2026, 9:52:51 PM (6 days ago)
Author:
Peter A. Buhr <pabuhr@…>
Branches:
master
Children:
e6e250d
Parents:
00675ed4
Message:

2nd attempt at harmonizing isOp functions, e.g., isEmpty, to C/C++ form empty

File:
1 edited

Legend:

Unmodified
Added
Removed
  • libcfa/src/concurrency/future.hfa

    r00675ed4 r81ab5eb  
    1010// Created On       : Wed Jan 06 17:33:18 2021
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Mon Nov 24 16:08:52 2025
    13 // Update Count     : 222
     12// Last Modified On : Sun Mar 29 21:13:04 2026
     13// Update Count     : 223
    1414//
    1515
     
    173173
    174174                bool fulfil$( future(T) & fut ) with( fut ) {   // helper
    175                         bool ret_val = ! isEmpty( waiters );
     175                        bool ret_val = ! empty( waiters );
    176176                        state = FUTURE_FULFILLED$;
    177                         while ( ! isEmpty( waiters ) ) {
     177                        while ( ! empty( waiters ) ) {
    178178                                if ( !__handle_waituntil_OR( waiters ) ) // handle special waituntil OR case
    179179                                        break; // if handle_OR returns false then waiters is empty so break
     
    211211                void reset( future(T) & fut ) with( fut ) {             // mark future as empty (for reuse)
    212212                        lock( lock );
    213                   if ( ! isEmpty( waiters ) ) abort( "Attempting to reset a future with blocked waiters" );
     213                  if ( ! empty( waiters ) ) abort( "Attempting to reset a future with blocked waiters" );
    214214                        state = FUTURE_EMPTY$;
    215215                        free( except );
Note: See TracChangeset for help on using the changeset viewer.