4
4
//! Whenever possible, please consider diagnostic items over hardcoded paths.
5
5
//! See <https://github.com/rust-lang/rust-clippy/issues/5393> for more information.
6
6
7
- #[ cfg( feature = "internal" ) ]
8
7
pub const APPLICABILITY : [ & str ; 2 ] = [ "rustc_lint_defs" , "Applicability" ] ;
9
- #[ cfg( feature = "internal" ) ]
10
8
pub const APPLICABILITY_VALUES : [ [ & str ; 3 ] ; 4 ] = [
11
9
[ "rustc_lint_defs" , "Applicability" , "Unspecified" ] ,
12
10
[ "rustc_lint_defs" , "Applicability" , "HasPlaceholders" ] ,
13
11
[ "rustc_lint_defs" , "Applicability" , "MaybeIncorrect" ] ,
14
12
[ "rustc_lint_defs" , "Applicability" , "MachineApplicable" ] ,
15
13
] ;
16
- #[ cfg( feature = "internal" ) ]
17
14
pub const DIAGNOSTIC_BUILDER : [ & str ; 3 ] = [ "rustc_errors" , "diagnostic_builder" , "DiagnosticBuilder" ] ;
18
15
pub const BINARYHEAP_ITER : [ & str ; 5 ] = [ "alloc" , "collections" , "binary_heap" , "BinaryHeap" , "iter" ] ;
19
16
pub const BTREEMAP_CONTAINS_KEY : [ & str ; 6 ] = [ "alloc" , "collections" , "btree" , "map" , "BTreeMap" , "contains_key" ] ;
@@ -25,9 +22,7 @@ pub const CORE_ITER_COPIED: [&str; 6] = ["core", "iter", "traits", "iterator", "
25
22
pub const CORE_ITER_FILTER : [ & str ; 6 ] = [ "core" , "iter" , "traits" , "iterator" , "Iterator" , "filter" ] ;
26
23
pub const CORE_RESULT_OK_METHOD : [ & str ; 4 ] = [ "core" , "result" , "Result" , "ok" ] ;
27
24
pub const CSTRING_AS_C_STR : [ & str ; 5 ] = [ "alloc" , "ffi" , "c_str" , "CString" , "as_c_str" ] ;
28
- #[ cfg( feature = "internal" ) ]
29
25
pub const EARLY_CONTEXT : [ & str ; 2 ] = [ "rustc_lint" , "EarlyContext" ] ;
30
- #[ cfg( feature = "internal" ) ]
31
26
pub const EARLY_LINT_PASS : [ & str ; 3 ] = [ "rustc_lint" , "passes" , "EarlyLintPass" ] ;
32
27
pub const F32_EPSILON : [ & str ; 4 ] = [ "core" , "f32" , "<impl f32>" , "EPSILON" ] ;
33
28
pub const F64_EPSILON : [ & str ; 4 ] = [ "core" , "f64" , "<impl f64>" , "EPSILON" ] ;
@@ -38,21 +33,14 @@ pub const FUTURES_IO_ASYNCWRITEEXT: [&str; 3] = ["futures_util", "io", "AsyncWri
38
33
pub const HASHMAP_CONTAINS_KEY : [ & str ; 6 ] = [ "std" , "collections" , "hash" , "map" , "HashMap" , "contains_key" ] ;
39
34
pub const HASHMAP_INSERT : [ & str ; 6 ] = [ "std" , "collections" , "hash" , "map" , "HashMap" , "insert" ] ;
40
35
pub const HASHSET_ITER : [ & str ; 6 ] = [ "std" , "collections" , "hash" , "set" , "HashSet" , "iter" ] ;
41
- #[ cfg( feature = "internal" ) ]
42
36
pub const IDENT : [ & str ; 3 ] = [ "rustc_span" , "symbol" , "Ident" ] ;
43
- #[ cfg( feature = "internal" ) ]
44
37
pub const IDENT_AS_STR : [ & str ; 4 ] = [ "rustc_span" , "symbol" , "Ident" , "as_str" ] ;
45
38
pub const INSERT_STR : [ & str ; 4 ] = [ "alloc" , "string" , "String" , "insert_str" ] ;
46
39
pub const ITERTOOLS_NEXT_TUPLE : [ & str ; 3 ] = [ "itertools" , "Itertools" , "next_tuple" ] ;
47
- #[ cfg( feature = "internal" ) ]
48
40
pub const KW_MODULE : [ & str ; 3 ] = [ "rustc_span" , "symbol" , "kw" ] ;
49
- #[ cfg( feature = "internal" ) ]
50
41
pub const LATE_CONTEXT : [ & str ; 2 ] = [ "rustc_lint" , "LateContext" ] ;
51
- #[ cfg( feature = "internal" ) ]
52
42
pub const LATE_LINT_PASS : [ & str ; 3 ] = [ "rustc_lint" , "passes" , "LateLintPass" ] ;
53
- #[ cfg( feature = "internal" ) ]
54
43
pub const LINT : [ & str ; 2 ] = [ "rustc_lint_defs" , "Lint" ] ;
55
- #[ cfg( feature = "internal" ) ]
56
44
pub const MSRV : [ & str ; 3 ] = [ "clippy_config" , "msrvs" , "Msrv" ] ;
57
45
pub const OS_STRING_AS_OS_STR : [ & str ; 5 ] = [ "std" , "ffi" , "os_str" , "OsString" , "as_os_str" ] ;
58
46
pub const OS_STR_TO_OS_STRING : [ & str ; 5 ] = [ "std" , "ffi" , "os_str" , "OsStr" , "to_os_string" ] ;
@@ -86,17 +74,11 @@ pub const STR_CHARS: [&str; 4] = ["core", "str", "<impl str>", "chars"];
86
74
pub const STR_ENDS_WITH : [ & str ; 4 ] = [ "core" , "str" , "<impl str>" , "ends_with" ] ;
87
75
pub const STR_LEN : [ & str ; 4 ] = [ "core" , "str" , "<impl str>" , "len" ] ;
88
76
pub const STR_STARTS_WITH : [ & str ; 4 ] = [ "core" , "str" , "<impl str>" , "starts_with" ] ;
89
- #[ cfg( feature = "internal" ) ]
90
77
pub const SYMBOL : [ & str ; 3 ] = [ "rustc_span" , "symbol" , "Symbol" ] ;
91
- #[ cfg( feature = "internal" ) ]
92
78
pub const SYMBOL_AS_STR : [ & str ; 4 ] = [ "rustc_span" , "symbol" , "Symbol" , "as_str" ] ;
93
- #[ cfg( feature = "internal" ) ]
94
79
pub const SYMBOL_INTERN : [ & str ; 4 ] = [ "rustc_span" , "symbol" , "Symbol" , "intern" ] ;
95
- #[ cfg( feature = "internal" ) ]
96
80
pub const SYMBOL_TO_IDENT_STRING : [ & str ; 4 ] = [ "rustc_span" , "symbol" , "Symbol" , "to_ident_string" ] ;
97
- #[ cfg( feature = "internal" ) ]
98
81
pub const SYM_MODULE : [ & str ; 3 ] = [ "rustc_span" , "symbol" , "sym" ] ;
99
- #[ cfg( feature = "internal" ) ]
100
82
pub const SYNTAX_CONTEXT : [ & str ; 3 ] = [ "rustc_span" , "hygiene" , "SyntaxContext" ] ;
101
83
#[ expect( clippy:: invalid_paths) ] // internal lints do not know about all external crates
102
84
pub const TOKIO_IO_ASYNCREADEXT : [ & str ; 5 ] = [ "tokio" , "io" , "util" , "async_read_ext" , "AsyncReadExt" ] ;
0 commit comments