2011-05-20 19:53:50 -07:00
|
|
|
// -*- rust -*-
|
|
|
|
// Tests that a function with a ! annotation always actually fails
|
|
|
|
|
2012-03-24 22:15:34 -07:00
|
|
|
fn bad_bang(i: uint) -> ! {
|
|
|
|
ret 7u;
|
2012-04-06 06:58:41 -07:00
|
|
|
//!^ ERROR expected `_|_` but found `uint`
|
2012-03-24 22:15:34 -07:00
|
|
|
}
|
2011-05-20 19:53:50 -07:00
|
|
|
|
2011-08-19 15:16:48 -07:00
|
|
|
fn main() { bad_bang(5u); }
|