]> git.lizzy.rs Git - rust.git/blob - src/test/ui/hygiene/arguments.rs
Rollup merge of #90202 - matthewjasper:xcrate-hygiene, r=petrochenkov
[rust.git] / src / test / ui / hygiene / arguments.rs
1 // ignore-pretty pretty-printing is unhygienic
2
3 #![feature(decl_macro)]
4
5 macro m($t:ty, $e:expr) {
6     mod foo {
7         #[allow(unused)]
8         struct S;
9         pub(super) fn f(_: $t) {}
10     }
11     foo::f($e);
12 }
13
14 fn main() {
15     struct S;
16     m!(S, S); //~ ERROR cannot find type `S` in this scope
17 }