rust/tests/ui/parser/issues/issue-68788-in-trait-item-propagation.rs

22 lines
341 B
Rust
Raw Normal View History

2020-02-05 05:27:45 -06:00
// Make sure we don't propagate restrictions on trait impl items to items inside them.
// check-pass
// edition:2018
fn main() {}
trait X {
fn foo();
}
impl X for () {
fn foo() {
struct S;
impl S {
pub const X: u8 = 0;
pub const fn bar() {}
async fn qux() {}
}
}
}