]> git.lizzy.rs Git - rust.git/blob - src/tools/clippy/tests/ui-internal/invalid_paths.rs
Rollup merge of #105768 - fee1-dead-contrib:iat-style, r=eholk
[rust.git] / src / tools / clippy / tests / ui-internal / invalid_paths.rs
1 #![warn(clippy::internal)]
2 #![allow(clippy::missing_clippy_version_attribute, clippy::unnecessary_def_path)]
3
4 mod paths {
5     // Good path
6     pub const ANY_TRAIT: [&str; 3] = ["std", "any", "Any"];
7
8     // Path to method on inherent impl of a primitive type
9     pub const F32_EPSILON: [&str; 4] = ["core", "f32", "<impl f32>", "EPSILON"];
10
11     // Path to method on inherent impl
12     pub const ARC_PTR_EQ: [&str; 4] = ["alloc", "sync", "Arc", "ptr_eq"];
13
14     // Path with empty segment
15     pub const TRANSMUTE: [&str; 4] = ["core", "intrinsics", "", "transmute"];
16
17     // Path with bad crate
18     pub const BAD_CRATE_PATH: [&str; 2] = ["bad", "path"];
19
20     // Path with bad module
21     pub const BAD_MOD_PATH: [&str; 2] = ["std", "xxx"];
22
23     // Path to method on an enum inherent impl
24     pub const OPTION_IS_SOME: [&str; 4] = ["core", "option", "Option", "is_some"];
25 }
26
27 fn main() {}