rust/tests/ui/hygiene/privacy-early.rs
2024-02-16 20:02:50 +00:00

18 lines
229 B
Rust

//@ edition:2018
#![feature(decl_macro)]
mod foo {
fn f() {}
macro f() {}
pub macro m() {
use f as g; //~ ERROR `f` is private, and cannot be re-exported
f!();
}
}
fn main() {
foo::m!();
}