From aee79294699153ac7da9d2e5d076192c6eee3238 Mon Sep 17 00:00:00 2001 From: Nick Desaulniers Date: Thu, 31 Jan 2013 17:51:01 -0800 Subject: Replace most invocations of fail keyword with die! macro --- src/libsyntax/parse/comments.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/libsyntax/parse/comments.rs') diff --git a/src/libsyntax/parse/comments.rs b/src/libsyntax/parse/comments.rs index 26de85548e1..8ed10fb138d 100644 --- a/src/libsyntax/parse/comments.rs +++ b/src/libsyntax/parse/comments.rs @@ -117,7 +117,7 @@ pub fn strip_doc_comment_decoration(comment: ~str) -> ~str { return str::connect(lines, ~"\n"); } - fail ~"not a doc-comment: " + comment; + die!(~"not a doc-comment: " + comment); } fn read_to_eol(rdr: string_reader) -> ~str { @@ -295,7 +295,7 @@ fn consume_comment(rdr: string_reader, code_to_the_left: bool, read_block_comment(rdr, code_to_the_left, comments); } else if rdr.curr == '#' && nextch(rdr) == '!' { read_shebang_comment(rdr, code_to_the_left, comments); - } else { fail; } + } else { die!(); } debug!("<<< consume comment"); } -- cgit 1.4.1-3-g733a5