diff options
Diffstat (limited to 'src/libstd/json.rs')
| -rw-r--r-- | src/libstd/json.rs | 10 |
1 files changed, 1 insertions, 9 deletions
diff --git a/src/libstd/json.rs b/src/libstd/json.rs index f1f736e01a1..a9b9b2977cd 100644 --- a/src/libstd/json.rs +++ b/src/libstd/json.rs @@ -35,6 +35,7 @@ pub enum Json { pub type List = ~[Json]; pub type Object = LinearMap<~str, Json>; +#[deriving(Eq)] pub struct Error { line: uint, col: uint, @@ -1060,15 +1061,6 @@ impl Ord for Json { fn gt(&self, other: &Json) -> bool { (*other).lt(&(*self)) } } -impl Eq for Error { - fn eq(&self, other: &Error) -> bool { - (*self).line == other.line && - (*self).col == other.col && - (*self).msg == other.msg - } - fn ne(&self, other: &Error) -> bool { !(*self).eq(other) } -} - trait ToJson { fn to_json(&self) -> Json; } impl ToJson for Json { |
