]> git.lizzy.rs Git - rust.git/blob - src/test/ui/rust-2018/uniform-paths/prelude-fail-2.rs
resolve: Prohibit use of imported tool modules
[rust.git] / src / test / ui / rust-2018 / uniform-paths / prelude-fail-2.rs
1 // edition:2018
2
3 #![feature(uniform_paths)]
4
5 // Built-in attribute
6 use inline as imported_inline;
7 mod builtin {
8     pub use inline as imported_inline;
9 }
10
11 // Tool module
12 use rustfmt as imported_rustfmt;
13 mod tool_mod {
14     pub use rustfmt as imported_rustfmt;
15 }
16
17 #[imported_inline] //~ ERROR cannot use a built-in attribute through an import
18 #[builtin::imported_inline] //~ ERROR cannot use a built-in attribute through an import
19 #[imported_rustfmt::skip] //~ ERROR cannot use a tool module through an import
20 #[tool_mod::imported_rustfmt::skip] //~ ERROR cannot use a tool module through an import
21 fn main() {}