2012-12-10 17:32:48 -08:00
|
|
|
// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
|
|
|
|
// file at the top-level directory of this distribution and at
|
|
|
|
// http://rust-lang.org/COPYRIGHT.
|
|
|
|
//
|
|
|
|
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
|
|
|
|
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
|
|
|
|
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
|
|
|
|
// option. This file may not be copied, modified, or distributed
|
|
|
|
// except according to those terms.
|
|
|
|
|
2014-04-14 21:00:31 +05:30
|
|
|
#![allow(path_statement)]
|
|
|
|
#![allow(unreachable_code)]
|
|
|
|
#![allow(unused_variable)]
|
2012-07-26 14:47:05 -07:00
|
|
|
|
|
|
|
fn id(x: bool) -> bool { x }
|
|
|
|
|
|
|
|
fn call_id() {
|
2014-10-09 15:17:22 -04:00
|
|
|
let c = panic!();
|
2012-07-26 14:47:05 -07:00
|
|
|
id(c);
|
|
|
|
}
|
|
|
|
|
2012-08-01 17:30:05 -07:00
|
|
|
fn call_id_2() { id(true) && id(return); }
|
2012-07-26 14:47:05 -07:00
|
|
|
|
2012-08-01 17:30:05 -07:00
|
|
|
fn call_id_3() { id(return) && id(return); }
|
2012-07-26 14:47:05 -07:00
|
|
|
|
|
|
|
fn ret_guard() {
|
2014-06-27 12:30:25 -07:00
|
|
|
match 2i {
|
2012-08-03 19:59:04 -07:00
|
|
|
x if (return) => { x; }
|
|
|
|
_ => {}
|
2012-07-26 14:47:05 -07:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2013-02-01 19:43:17 -08:00
|
|
|
pub fn main() {}
|