Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/libcfa/concurrency/alarm.c

    rc2b9f21 rc40e7c5  
    4141void ?{}( __cfa_time_t & this, zero_t zero ) { this.val = 0; }
    4242
    43 void ?{}( itimerval & this, __cfa_time_t * alarm ) {
    44         this.it_value.tv_sec = alarm->val / one_second;                 // seconds
    45         this.it_value.tv_usec = max( (alarm->val % one_second) / one_microsecond, 1000 ); // microseconds
    46         this.it_interval.tv_sec = 0;
    47         this.it_interval.tv_usec = 0;
     43void ?{}( itimerval & this, __cfa_time_t * alarm ) with( this ) {
     44        it_value.tv_sec = alarm->val / one_second;                      // seconds
     45        it_value.tv_usec = max( (alarm->val % one_second) / one_microsecond, 1000 ); // microseconds
     46        it_interval.tv_sec = 0;
     47        it_interval.tv_usec = 0;
    4848}
    4949
     
    8484//=============================================================================================
    8585
    86 void ?{}( alarm_node_t & this, thread_desc * thrd, __cfa_time_t alarm = zero_time, __cfa_time_t period = zero_time ) {
     86void ?{}( alarm_node_t & this, thread_desc * thrd, __cfa_time_t alarm = zero_time, __cfa_time_t period = zero_time ) with( this ) {
    8787        this.thrd = thrd;
    8888        this.alarm = alarm;
    8989        this.period = period;
    90         this.next = 0;
    91         this.set = false;
    92         this.kernel_alarm = false;
    93 }
    94 
    95 void ?{}( alarm_node_t & this, processor   * proc, __cfa_time_t alarm = zero_time, __cfa_time_t period = zero_time ) {
     90        next = 0;
     91        set = false;
     92        kernel_alarm = false;
     93}
     94
     95void ?{}( alarm_node_t & this, processor   * proc, __cfa_time_t alarm = zero_time, __cfa_time_t period = zero_time ) with( this ) {
    9696        this.proc = proc;
    9797        this.alarm = alarm;
    9898        this.period = period;
    99         this.next = 0;
    100         this.set = false;
    101         this.kernel_alarm = true;
     99        next = 0;
     100        set = false;
     101        kernel_alarm = true;
    102102}
    103103
Note: See TracChangeset for help on using the changeset viewer.