1 // aux-build:macro_pub_in_module.rs
4 // @has external_crate/some_module/macro.external_macro.html
7 #![feature(decl_macro, no_core, rustc_attrs)]
8 #![crate_name = "krate"]
11 extern crate external_crate;
14 // @has krate/inner/macro.raw_const.html
15 pub macro raw_const() {}
17 // @has krate/inner/macro.test.html
18 #[rustc_builtin_macro]
19 pub macro test($item:item) {}
21 // @has krate/inner/macro.Clone.html
22 #[rustc_builtin_macro]
23 pub macro Clone($item:item) {}
25 // Make sure the logic is not affected by a re-export.
29 // @has krate/inner/macro.renamed.html
30 pub use private::m as renamed;
32 // @has krate/inner/macro.external_macro.html
33 pub use ::external_crate::some_module::external_macro;
36 // Namespaces: Make sure the logic does not mix up a function name with a module nameā¦
37 fn both_fn_and_mod() {
40 pub mod both_fn_and_mod {
41 // @!has krate/both_fn_and_mod/macro.m.html
48 // @!has krate/__/macro.m.html