summary refs log tree commit diff
path: root/tests/ui/parser/impls-nested-within-fns-semantic-1.rs
blob: 92823b05af840efa479a0f9bd6e4f53e2d178db6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
// Regression test for part of issue #119924.
//@ check-pass
//@ compile-flags: -Znext-solver

#![allow(incomplete_features)]
#![feature(const_trait_impl, effects)]

#[const_trait]
trait Trait {
    fn required();
}

impl const Trait for () {
    fn required() {
        pub struct Type;

        impl Type {
            // This visibility qualifier used to get rejected.
            pub fn perform() {}
        }
    }
}

fn main() {}