blob: 1a4dfda090970c038f3e92e8a03bf65ee1449c1e [file] [log] [blame] [edit]
//@ compile-flags:--test
struct A {}
impl A {
#[test]
//~^ ERROR the `#[test]` attribute may only be used on a non-associated function
fn new() -> A {
A {}
}
#[test]
//~^ ERROR the `#[test]` attribute may only be used on a non-associated function
fn recovery_witness() -> A {
A {}
}
}
#[test]
fn test() {
let _ = A::new();
}
fn main() {}