rust/tests/ui/legacy_numeric_constants.stderr

185 lines
4.3 KiB
Plaintext

error: usage of a legacy numeric constant
--> tests/ui/legacy_numeric_constants.rs:31:5
|
LL | std::f32::EPSILON;
| ^^^^^^^^^^^^^^^^^
|
= note: `-D clippy::legacy-numeric-constants` implied by `-D warnings`
= help: to override `-D warnings` add `#[allow(clippy::legacy_numeric_constants)]`
help: use the associated constant instead
|
LL | f32::EPSILON;
| ~~~~~~~~~~~~
error: usage of a legacy numeric constant
--> tests/ui/legacy_numeric_constants.rs:34:5
|
LL | std::u8::MIN;
| ^^^^^^^^^^^^
|
help: use the associated constant instead
|
LL | u8::MIN;
| ~~~~~~~
error: usage of a legacy numeric constant
--> tests/ui/legacy_numeric_constants.rs:37:5
|
LL | std::usize::MIN;
| ^^^^^^^^^^^^^^^
|
help: use the associated constant instead
|
LL | usize::MIN;
| ~~~~~~~~~~
error: usage of a legacy numeric constant
--> tests/ui/legacy_numeric_constants.rs:40:5
|
LL | std::u32::MAX;
| ^^^^^^^^^^^^^
|
help: use the associated constant instead
|
LL | u32::MAX;
| ~~~~~~~~
error: usage of a legacy numeric constant
--> tests/ui/legacy_numeric_constants.rs:43:5
|
LL | core::u32::MAX;
| ^^^^^^^^^^^^^^
|
help: use the associated constant instead
|
LL | u32::MAX;
| ~~~~~~~~
error: usage of a legacy numeric constant
--> tests/ui/legacy_numeric_constants.rs:46:5
|
LL | MAX;
| ^^^
|
help: use the associated constant instead
|
LL | u32::MAX;
| ~~~~~~~~
error: usage of a legacy numeric method
--> tests/ui/legacy_numeric_constants.rs:49:10
|
LL | i32::max_value();
| ^^^^^^^^^^^
|
help: use the associated constant instead
|
LL | i32::MAX;
| ~~~
error: usage of a legacy numeric method
--> tests/ui/legacy_numeric_constants.rs:52:9
|
LL | u8::max_value();
| ^^^^^^^^^^^
|
help: use the associated constant instead
|
LL | u8::MAX;
| ~~~
error: usage of a legacy numeric method
--> tests/ui/legacy_numeric_constants.rs:55:9
|
LL | u8::min_value();
| ^^^^^^^^^^^
|
help: use the associated constant instead
|
LL | u8::MIN;
| ~~~
error: usage of a legacy numeric constant
--> tests/ui/legacy_numeric_constants.rs:58:5
|
LL | ::std::u8::MIN;
| ^^^^^^^^^^^^^^
|
help: use the associated constant instead
|
LL | u8::MIN;
| ~~~~~~~
error: usage of a legacy numeric method
--> tests/ui/legacy_numeric_constants.rs:61:27
|
LL | ::std::primitive::u8::min_value();
| ^^^^^^^^^^^
|
help: use the associated constant instead
|
LL | ::std::primitive::u8::MIN;
| ~~~
error: usage of a legacy numeric method
--> tests/ui/legacy_numeric_constants.rs:64:26
|
LL | std::primitive::i32::max_value();
| ^^^^^^^^^^^
|
help: use the associated constant instead
|
LL | std::primitive::i32::MAX;
| ~~~
error: usage of a legacy numeric constant
--> tests/ui/legacy_numeric_constants.rs:67:5
|
LL | self::a::u128::MAX;
| ^^^^^^^^^^^^^^^^^^
|
help: use the associated constant instead
|
LL | u128::MAX;
| ~~~~~~~~~
error: usage of a legacy numeric constant
--> tests/ui/legacy_numeric_constants.rs:17:25
|
LL | let x = std::u64::MAX;
| ^^^^^^^^^^^^^
...
LL | b!();
| ---- in this macro invocation
|
= note: this error originates in the macro `b` (in Nightly builds, run with -Z macro-backtrace for more info)
help: use the associated constant instead
|
LL | let x = u64::MAX;
| ~~~~~~~~
error: usage of a legacy numeric constant
--> tests/ui/legacy_numeric_constants.rs:81:14
|
LL | [(0, "", std::i128::MAX)];
| ^^^^^^^^^^^^^^
|
help: use the associated constant instead
|
LL | [(0, "", i128::MAX)];
| ~~~~~~~~~
error: usage of a legacy numeric constant
--> tests/ui/legacy_numeric_constants.rs:115:5
|
LL | std::u32::MAX;
| ^^^^^^^^^^^^^
|
help: use the associated constant instead
|
LL | u32::MAX;
| ~~~~~~~~
error: aborting due to 16 previous errors