Ignore:
File:
1 edited

Legend:

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

    r2fe64ba r8a97248  
    1919#include "invoke.h"
    2020#include "../exception.hfa"
    21 
    22 //-----------------------------------------------------------------------------
    23 // Type used to store and queue nonlocal exceptions on coroutines
    24 struct nonlocal_exception {
    25     exception_t * the_exception;
    26     nonlocal_exception * next;
    27 };
    28 static inline void ?{} ( nonlocal_exception & this, exception_t * ex ) with(this) {
    29     the_exception = ex;
    30     next = 0p;
    31 }
    32 
    33 static inline nonlocal_exception *& get_next( nonlocal_exception & this ) __attribute__((const)) {
    34     return this.next;
    35 }
    3621
    3722//-----------------------------------------------------------------------------
     
    218203}
    219204
    220 // non local ehm routines
    221 forall(T & | is_coroutine(T)) {
    222     void enable_ehm( T & cor );
    223     void disable_ehm( T & cor );
    224     bool poll( T & cor );
    225     bool checked_poll( T & cor );
    226 }
    227 
    228 // trait for exceptions able to be resumed at another coroutine
    229 forall(exceptT &, T & | is_coroutine(T))
    230 trait ehm_resume_at { void $throwResume(exceptT &); };
    231 
    232 forall(exceptT &, T & | ehm_resume_at( exceptT, T ))
    233 void resumeAt( T & receiver, exceptT & ex );
    234 
    235205// Local Variables: //
    236206// mode: c //
Note: See TracChangeset for help on using the changeset viewer.