Update run-make tests.

This commit is contained in:
Michael Woerister 2017-10-30 18:21:06 +01:00
parent 7d774c4214
commit 48a8d23b97
4 changed files with 16 additions and 2 deletions

View File

@ -13,6 +13,7 @@ fn outer<T>() {
fn inner() -> u32 { fn inner() -> u32 {
8675309 8675309
} }
inner();
} }
extern "C" fn outer_foreign<T>() { extern "C" fn outer_foreign<T>() {
@ -20,6 +21,7 @@ extern "C" fn outer_foreign<T>() {
fn inner() -> u32 { fn inner() -> u32 {
11235813 11235813
} }
inner();
} }
fn main() { fn main() {

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed // option. This file may not be copied, modified, or distributed
// except according to those terms. // except according to those terms.
fn magic_fn() -> usize { fn magic_fn() -> usize {
1234 1234
} }
@ -24,4 +26,8 @@ mod b {
} }
} }
fn main() { } fn main() {
magic_fn();
a::magic_fn();
b::magic_fn();
}

View File

@ -14,7 +14,8 @@ pub static Y: &'static [u8] = include_bytes!("lib.rs");
trait Foo { fn dummy(&self) { } } trait Foo { fn dummy(&self) { } }
impl Foo for usize {} impl Foo for usize {}
pub fn dummy() { #[no_mangle]
pub extern "C" fn dummy() {
// force the vtable to be created // force the vtable to be created
let _x = &1usize as &Foo; let _x = &1usize as &Foo;
} }

View File

@ -17,3 +17,8 @@ impl Def {
Def { id: id } Def { id: id }
} }
} }
#[no_mangle]
pub fn user() {
let _ = Def::new(0);
}