Add inline compile-fail markers to tests
This commit is contained in:
parent
f103342b8f
commit
0e241d0059
5 changed files with 5 additions and 0 deletions
|
|
@ -9,6 +9,7 @@
|
|||
// except according to those terms.
|
||||
|
||||
pub foo(s: usize) { bar() }
|
||||
//~^ ERROR missing `fn` for method definition
|
||||
|
||||
fn main() {
|
||||
foo(2);
|
||||
|
|
|
|||
|
|
@ -9,5 +9,6 @@
|
|||
// except according to those terms.
|
||||
|
||||
pub S();
|
||||
//~^ ERROR missing `fn` or `struct` for method or struct definition
|
||||
|
||||
fn main() {}
|
||||
|
|
|
|||
|
|
@ -9,5 +9,6 @@
|
|||
// except according to those terms.
|
||||
|
||||
pub S (foo) bar
|
||||
//~^ ERROR missing `fn` or `struct` for method or struct definition
|
||||
|
||||
fn main() {}
|
||||
|
|
|
|||
|
|
@ -9,6 +9,7 @@
|
|||
// except according to those terms.
|
||||
|
||||
pub foo(s: usize) -> bool { true }
|
||||
//~^ ERROR missing `fn` for method definition
|
||||
|
||||
fn main() {
|
||||
foo(2);
|
||||
|
|
|
|||
|
|
@ -9,5 +9,6 @@
|
|||
// except according to those terms.
|
||||
|
||||
pub S {
|
||||
//~^ ERROR missing `struct` for struct definition
|
||||
}
|
||||
fn main() {}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue