2015-01-03 09:45:00 -06:00
|
|
|
fn with<F>(f: F) where F: FnOnce(&String) {}
|
2013-06-20 14:11:47 -05:00
|
|
|
|
2014-05-22 18:57:53 -05:00
|
|
|
fn arg_item(&_x: &String) {}
|
2019-04-22 02:40:08 -05:00
|
|
|
//~^ ERROR [E0507]
|
2013-06-20 14:11:47 -05:00
|
|
|
|
|
|
|
fn arg_closure() {
|
|
|
|
with(|&_x| ())
|
2019-04-22 02:40:08 -05:00
|
|
|
//~^ ERROR [E0507]
|
2013-06-20 14:11:47 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
fn let_pat() {
|
2014-05-25 05:10:11 -05:00
|
|
|
let &_x = &"hi".to_string();
|
2019-04-22 02:40:08 -05:00
|
|
|
//~^ ERROR [E0507]
|
2013-06-20 14:11:47 -05:00
|
|
|
}
|
|
|
|
|
2013-09-23 19:20:36 -05:00
|
|
|
pub fn main() {}
|