about summary refs log tree commit diff
path: root/src/libsyntax/parse/comments.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/libsyntax/parse/comments.rs')
-rw-r--r--src/libsyntax/parse/comments.rs11
1 files changed, 1 insertions, 10 deletions
diff --git a/src/libsyntax/parse/comments.rs b/src/libsyntax/parse/comments.rs
index 1b6b25db38a..e5685cdb4c7 100644
--- a/src/libsyntax/parse/comments.rs
+++ b/src/libsyntax/parse/comments.rs
@@ -20,13 +20,13 @@ use parse::lexer;
 use parse::token;
 use parse;
 
-use core::cmp;
 use core::io::ReaderUtil;
 use core::io;
 use core::str;
 use core::uint;
 use core::vec;
 
+#[deriving(Eq)]
 pub enum cmnt_style {
     isolated, // No code on either side of each line of the comment
     trailing, // Code exists to the left of the comment
@@ -34,15 +34,6 @@ pub enum cmnt_style {
     blank_line, // Just a manual blank line "\n\n", for layout
 }
 
-impl cmp::Eq for cmnt_style {
-    fn eq(&self, other: &cmnt_style) -> bool {
-        ((*self) as uint) == ((*other) as uint)
-    }
-    fn ne(&self, other: &cmnt_style) -> bool {
-        ((*self) as uint) != ((*other) as uint)
-    }
-}
-
 pub struct cmnt {
     style: cmnt_style,
     lines: ~[~str],