Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/libcfa/concurrency/thread

    rcb0e6de r17af7d1  
    2222
    2323#include "coroutine"
    24 #include "monitor"
    2524
    2625//-----------------------------------------------------------------------------
     
    2928// Anything that is resumed is a coroutine.
    3029trait is_thread(dtype T) {
    31       void ^?{}(T* mutex this);
     30      void ^?{}(T* this);
    3231      void main(T* this);
    3332      thread_desc* get_thread(T* this);
     
    4140}
    4241
    43 forall( dtype T | is_thread(T) )
    44 static inline monitor_desc* get_monitor(T * this) {
    45         return &get_thread(this)->mon;
    46 }
    47 
    48 static inline coroutine_desc* get_coroutine(thread_desc * this) {
     42static inline coroutine_desc* get_coroutine(thread_desc* this) {
    4943        return &this->cor;
    50 }
    51 
    52 static inline monitor_desc* get_monitor(thread_desc * this) {
    53         return &this->mon;
    5444}
    5545
Note: See TracChangeset for help on using the changeset viewer.