Branch: Tag:

2016-02-11

2016-02-11 22:49:38 by Martin Nilsson <nilsson@fastmail.com>

More readable macros.

411:      #define THREADSTATE2OBJ(X) ((X)->thread_obj)    - #if defined(PIKE_DEBUG) + #ifdef PIKE_DEBUG      /* This is a debug wrapper to enable checks that the interpreter lock    * is held by the current thread. */
450:   #define SET_LOCKING_THREAD 0   #define UNSET_LOCKING_THREAD 0    - #endif + #endif /* PIKE_DEBUG */      PMOD_EXPORT void pike_low_lock_interpreter (DLOC_DECL)   {
1707:    * holding it. */    low_mt_lock_interpreter();    - #if defined(PIKE_DEBUG) + #ifdef PIKE_DEBUG    if(d_flag) {    THREAD_T self = th_self();    if( !th_equal(arg.thread_state->id, self) )    Pike_fatal("Current thread is wrong. %lx %lx\n",    (long)arg.thread_state->id, (long)self);    } - #endif + #endif /* PIKE_DEBUG */       arg.thread_state->swapped = 0;    Pike_interpreter_pointer = &arg.thread_state->state;