Update tests
This commit is contained in:
parent
b285ebc48e
commit
877ed0d068
@ -18,6 +18,6 @@ fn main() {
|
||||
let a = 1i32;
|
||||
foo!(a);
|
||||
|
||||
foo!(1.i32.foo());
|
||||
foo!(1i32.foo());
|
||||
//~^ ERROR attempted access of field `i32` on type `_`, but no field with that name was found
|
||||
}
|
||||
|
@ -16,5 +16,7 @@ macro_rules! not_an_lvalue {
|
||||
}
|
||||
|
||||
fn main() {
|
||||
|
||||
0 = 42;
|
||||
not_an_lvalue!(99);
|
||||
}
|
||||
|
@ -24,7 +24,7 @@ macro_rules! write {
|
||||
unsafe {
|
||||
write(stdout, $arr.as_ptr() as *const i8,
|
||||
$arr.len() * size_of($arr[0]));
|
||||
//~^ ERROR mismatched types: expected `u64`, found `usize`
|
||||
//~^ ERROR mismatched types
|
||||
}
|
||||
}}
|
||||
}
|
||||
|
@ -10,5 +10,5 @@
|
||||
|
||||
fn main() {
|
||||
assert!("foo");
|
||||
//~^ ERROR cannot apply unary operator `!` to type `&'static str`'`
|
||||
//~^ ERROR cannot apply unary operator `!` to type `&'static str`
|
||||
}
|
||||
|
@ -12,7 +12,7 @@ macro_rules! foo {
|
||||
($d:expr) => {{
|
||||
fn bar(d: u8) { }
|
||||
bar(&mut $d);
|
||||
//~^ ERROR mismatched types: expected `u8`, found `&mut u8`
|
||||
//~^ ERROR mismatched types
|
||||
}}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user