File tree Expand file tree Collapse file tree 2 files changed +8
-5
lines changed
branches/try/src/libsyntax Expand file tree Collapse file tree 2 files changed +8
-5
lines changed Original file line number Diff line number Diff line change 2
2
refs/heads/master: 61b1875c16de39c166b0f4d54bba19f9c6777d1a
3
3
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
4
4
refs/heads/snap-stage3: 4a81779abd786ff22d71434c6d9a5917ea4cdfff
5
- refs/heads/try: 9e3e57c58bebe1f8d6872c62be8f8b697846109b
5
+ refs/heads/try: cba77ffbfa469727314f65405117277839a1783b
6
6
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
Original file line number Diff line number Diff line change @@ -86,11 +86,14 @@ impl codemap_handler of handler for handler_t {
86
86
}
87
87
fn has_errors ( ) -> bool { self . err_count > 0 u }
88
88
fn abort_if_errors ( ) {
89
- if self . err_count > 0 u {
90
- let s = #fmt[ "aborting due to %u previous errors" ,
91
- self . err_count ] ;
92
- self . fatal ( s) ;
89
+ let s;
90
+ alt self. err_count {
91
+ 0 u { ret; }
92
+ 1 u { s = "aborting due to previous error" ; }
93
+ _ { s = #fmt[ "aborting due to %u previous errors",
94
+ self.err_count]; }
93
95
}
96
+ self.fatal(s);
94
97
}
95
98
fn warn(msg: str) {
96
99
self.emit(none, msg, warning);
You can’t perform that action at this time.
0 commit comments