about summary refs log tree commit diff
path: root/src/libstd
diff options
context:
space:
mode:
Diffstat (limited to 'src/libstd')
-rw-r--r--src/libstd/nil.rs11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/libstd/nil.rs b/src/libstd/nil.rs
index 40f6d53ed22..81b7662e581 100644
--- a/src/libstd/nil.rs
+++ b/src/libstd/nil.rs
@@ -16,6 +16,10 @@ Functions for the unit type.
 
 #[cfg(not(test))]
 use prelude::*;
+#[cfg(not(test))]
+use num::Zero;
+
+
 
 #[cfg(not(test))]
 impl Eq for () {
@@ -48,3 +52,10 @@ impl TotalEq for () {
     #[inline]
     fn equals(&self, _other: &()) -> bool { true }
 }
+
+#[cfg(not(test))]
+impl Zero for () {
+    fn zero() -> () { () }
+    fn is_zero(&self) -> bool { true }
+}
+