about summary refs log tree commit diff
path: root/src/libstd/unstable
diff options
context:
space:
mode:
Diffstat (limited to 'src/libstd/unstable')
-rw-r--r--src/libstd/unstable/mutex.rs8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/libstd/unstable/mutex.rs b/src/libstd/unstable/mutex.rs
index 69c6204cc32..ba965f2b5c5 100644
--- a/src/libstd/unstable/mutex.rs
+++ b/src/libstd/unstable/mutex.rs
@@ -1,4 +1,4 @@
-// Copyright 2013 The Rust Project Developers. See the COPYRIGHT
+// Copyright 2013-2014 The Rust Project Developers. See the COPYRIGHT
 // file at the top-level directory of this distribution and at
 // http://rust-lang.org/COPYRIGHT.
 //
@@ -389,9 +389,9 @@ impl Once {
 
         let prev = self.cnt.fetch_add(1, atomics::SeqCst);
         if prev < 0 {
-            // Make sure we never overflow, we'll never have int::min_value
+            // Make sure we never overflow, we'll never have int::MIN
             // simultaneous calls to `doit` to make this value go back to 0
-            self.cnt.store(int::min_value, atomics::SeqCst);
+            self.cnt.store(int::MIN, atomics::SeqCst);
             return
         }
 
@@ -401,7 +401,7 @@ impl Once {
         unsafe { self.mutex.lock() }
         if self.cnt.load(atomics::SeqCst) > 0 {
             f();
-            let prev = self.cnt.swap(int::min_value, atomics::SeqCst);
+            let prev = self.cnt.swap(int::MIN, atomics::SeqCst);
             self.lock_cnt.store(prev, atomics::SeqCst);
         }
         unsafe { self.mutex.unlock() }