diff options
| author | Tim Chevalier <chevalier@alum.wellesley.edu> | 2012-06-25 13:29:41 -0700 |
|---|---|---|
| committer | Tim Chevalier <chevalier@alum.wellesley.edu> | 2012-06-25 13:29:41 -0700 |
| commit | da470ff5b8b970c90b4dce3885a2908d477c1021 (patch) | |
| tree | f65aa2d105f18cdeb79321a37e47e26a5f592149 /src/rt | |
| parent | 44d0a061be0ec9cae51c61b7bb335e8c4b8c6cf5 (diff) | |
| parent | fad307d7b4aa5e7ff6cf30194b069062aaad1a89 (diff) | |
| download | rust-da470ff5b8b970c90b4dce3885a2908d477c1021.tar.gz rust-da470ff5b8b970c90b4dce3885a2908d477c1021.zip | |
Merge
Diffstat (limited to 'src/rt')
| -rw-r--r-- | src/rt/rust_builtin.cpp | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/src/rt/rust_builtin.cpp b/src/rt/rust_builtin.cpp index cab1b6b427c..ad729494c45 100644 --- a/src/rt/rust_builtin.cpp +++ b/src/rt/rust_builtin.cpp @@ -891,9 +891,7 @@ rust_unlock_cond_lock(rust_cond_lock *lock) { extern "C" void rust_wait_cond_lock(rust_cond_lock *lock) { rust_task *task = rust_get_current_task(); -#ifdef DEBUG_LOCKS - assert(lock->lock.lock_held_by_current_thread()); -#endif + lock->lock.must_have_lock(); assert(NULL == lock->waiting); lock->waiting = task; task->block(lock, "waiting for signal"); @@ -905,9 +903,7 @@ rust_wait_cond_lock(rust_cond_lock *lock) { extern "C" bool rust_signal_cond_lock(rust_cond_lock *lock) { -#ifdef DEBUG_LOCKS - assert(lock->lock.lock_held_by_current_thread()); -#endif + lock->lock.must_have_lock(); if(NULL == lock->waiting) { return false; } |
