diff options
Diffstat (limited to 'src/libsyntax/parse/comments.rs')
| -rw-r--r-- | src/libsyntax/parse/comments.rs | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/libsyntax/parse/comments.rs b/src/libsyntax/parse/comments.rs index b85262cb79d..7fcf7a032dc 100644 --- a/src/libsyntax/parse/comments.rs +++ b/src/libsyntax/parse/comments.rs @@ -17,6 +17,15 @@ enum cmnt_style { blank_line, // Just a manual blank line "\n\n", for layout } +impl cmnt_style : cmp::Eq { + pure fn eq(&&other: cmnt_style) -> bool { + (self as uint) == (other as uint) + } + pure fn ne(&&other: cmnt_style) -> bool { + (self as uint) != (other as uint) + } +} + type cmnt = {style: cmnt_style, lines: ~[~str], pos: uint}; fn is_doc_comment(s: ~str) -> bool { |
