about summary refs log tree commit diff
path: root/src/rt/rust_task.cpp
diff options
context:
space:
mode:
authorBrian Anderson <banderson@mozilla.com>2012-03-30 18:37:30 -0700
committerBrian Anderson <banderson@mozilla.com>2012-03-31 19:51:29 -0700
commitc8dc6fcb4cd29e5fb6c509149871b869b951295d (patch)
tree3556f9f57afa10a2f14c4ff44042b6db174ded2a /src/rt/rust_task.cpp
parent609144f7a6adba552602feb7e50e7c4d6a815fae (diff)
downloadrust-c8dc6fcb4cd29e5fb6c509149871b869b951295d.tar.gz
rust-c8dc6fcb4cd29e5fb6c509149871b869b951295d.zip
Revert "rt: Remove lock_held_by_current_thread"
Adds back the ability to make assertions about locks, but only under the
--enable-debug configuration

This reverts commit b247de64583e2ab527088813ba9192824554e801.

Conflicts:

	src/rt/rust_sched_loop.cpp
Diffstat (limited to 'src/rt/rust_task.cpp')
-rw-r--r--src/rt/rust_task.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/rt/rust_task.cpp b/src/rt/rust_task.cpp
index d276b5c904b..4ab1f4680eb 100644
--- a/src/rt/rust_task.cpp
+++ b/src/rt/rust_task.cpp
@@ -212,6 +212,7 @@ rust_task::must_fail_from_being_killed() {
 
 bool
 rust_task::must_fail_from_being_killed_unlocked() {
+    kill_lock.must_have_lock();
     return killed && !reentered_rust_stack;
 }