rust/tests/ui/rfc-2632-const-trait-impl/const-impl-norecover.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

13 lines
239 B
Rust
Raw Normal View History

2020-12-03 12:37:19 -06:00
#![feature(const_trait_impl)]
struct Foo;
const impl Foo { //~ ERROR: expected identifier, found keyword
fn bar() {}
}
fn main() {
// shouldn't error here because we shouldn't have been able to recover above
Foo::bar();
}