2024-02-16 20:02:50 +00:00
|
|
|
//@ run-pass
|
2018-09-25 21:51:35 +00:00
|
|
|
#![allow(dead_code)]
|
2014-05-06 01:56:44 +00:00
|
|
|
|
2024-02-16 20:02:50 +00:00
|
|
|
//@ pretty-expanded FIXME #23616
|
2015-03-22 20:13:15 +00:00
|
|
|
|
2015-03-26 00:06:52 +00:00
|
|
|
fn borrow(_v: &isize) {}
|
2012-04-26 23:02:01 +00:00
|
|
|
|
2015-03-26 00:06:52 +00:00
|
|
|
fn borrow_from_arg_imm_ref(v: Box<isize>) {
|
2014-07-07 23:35:15 +00:00
|
|
|
borrow(&*v);
|
2012-04-26 23:02:01 +00:00
|
|
|
}
|
|
|
|
|
2015-03-26 00:06:52 +00:00
|
|
|
fn borrow_from_arg_mut_ref(v: &mut Box<isize>) {
|
2014-07-07 23:35:15 +00:00
|
|
|
borrow(&**v);
|
2012-04-26 23:02:01 +00:00
|
|
|
}
|
|
|
|
|
2015-03-26 00:06:52 +00:00
|
|
|
fn borrow_from_arg_copy(v: Box<isize>) {
|
2014-07-07 23:35:15 +00:00
|
|
|
borrow(&*v);
|
2012-04-26 23:02:01 +00:00
|
|
|
}
|
|
|
|
|
2013-02-02 03:43:17 +00:00
|
|
|
pub fn main() {
|
2012-04-26 23:02:01 +00:00
|
|
|
}
|