]> git.lizzy.rs Git - rust.git/blob - tests/ui/lint/test-inner-fn.rs
Auto merge of #106884 - clubby789:fieldless-enum-debug, r=michaelwoerister
[rust.git] / tests / ui / lint / test-inner-fn.rs
1 // compile-flags: --test -D unnameable_test_items
2
3 #[test]
4 fn foo() {
5     #[test] //~ ERROR cannot test inner items [unnameable_test_items]
6     fn bar() {}
7     bar();
8 }
9
10 mod x {
11     #[test]
12     fn foo() {
13         #[test] //~ ERROR cannot test inner items [unnameable_test_items]
14         fn bar() {}
15         bar();
16     }
17 }
18
19 fn main() {}