summaryrefslogtreecommitdiffstats
path: root/src/tools/clippy/tests/ui/default_numeric_fallback_i32.fixed
diff options
context:
space:
mode:
Diffstat (limited to 'src/tools/clippy/tests/ui/default_numeric_fallback_i32.fixed')
-rw-r--r--src/tools/clippy/tests/ui/default_numeric_fallback_i32.fixed20
1 files changed, 9 insertions, 11 deletions
diff --git a/src/tools/clippy/tests/ui/default_numeric_fallback_i32.fixed b/src/tools/clippy/tests/ui/default_numeric_fallback_i32.fixed
index 3f4994f04..b7485b73d 100644
--- a/src/tools/clippy/tests/ui/default_numeric_fallback_i32.fixed
+++ b/src/tools/clippy/tests/ui/default_numeric_fallback_i32.fixed
@@ -1,5 +1,5 @@
// run-rustfix
-// aux-build:macro_rules.rs
+// aux-build:proc_macros.rs
#![feature(lint_reasons)]
#![warn(clippy::default_numeric_fallback)]
@@ -9,11 +9,12 @@
clippy::no_effect,
clippy::unnecessary_operation,
clippy::branches_sharing_code,
- clippy::let_unit_value
+ clippy::let_unit_value,
+ clippy::let_with_type_underscore
)]
-#[macro_use]
-extern crate macro_rules;
+extern crate proc_macros;
+use proc_macros::{external, inline_macros};
mod basic_expr {
fn test() {
@@ -167,20 +168,17 @@ mod method_calls {
}
mod in_macro {
- macro_rules! internal_macro {
- () => {
- let x = 22_i32;
- };
- }
+ use super::*;
// Should lint in internal macro.
+ #[inline_macros]
fn internal() {
- internal_macro!();
+ inline!(let x = 22_i32;);
}
// Should NOT lint in external macro.
fn external() {
- default_numeric_fallback!();
+ external!(let x = 22;);
}
}