about summary refs log tree commit diff
path: root/clippy_dev
diff options
context:
space:
mode:
Diffstat (limited to 'clippy_dev')
-rw-r--r--clippy_dev/src/fmt.rs6
-rw-r--r--clippy_dev/src/new_lint.rs4
2 files changed, 5 insertions, 5 deletions
diff --git a/clippy_dev/src/fmt.rs b/clippy_dev/src/fmt.rs
index c6673859282..790dafa811f 100644
--- a/clippy_dev/src/fmt.rs
+++ b/clippy_dev/src/fmt.rs
@@ -179,8 +179,8 @@ fn fmt_conf(check: bool) -> Result<(), Error> {
                 #[expect(clippy::drain_collect)]
                 fields.push(ClippyConf {
                     name,
-                    lints: lints.drain(..).collect(),
                     attrs: &conf[attrs_start..attrs_end],
+                    lints: lints.drain(..).collect(),
                     field: conf[field_start..i].trim_end(),
                 });
                 attrs_start = i;
@@ -191,8 +191,8 @@ fn fmt_conf(check: bool) -> Result<(), Error> {
                 #[expect(clippy::drain_collect)]
                 fields.push(ClippyConf {
                     name,
-                    lints: lints.drain(..).collect(),
                     attrs: &conf[attrs_start..attrs_end],
+                    lints: lints.drain(..).collect(),
                     field: conf[field_start..i].trim_end(),
                 });
                 attrs_start = i;
@@ -220,8 +220,8 @@ fn fmt_conf(check: bool) -> Result<(), Error> {
     }
     fields.push(ClippyConf {
         name,
-        lints,
         attrs: &conf[attrs_start..attrs_end],
+        lints,
         field: conf[field_start..].trim_end(),
     });
 
diff --git a/clippy_dev/src/new_lint.rs b/clippy_dev/src/new_lint.rs
index 24d1a53266a..35dd986ff61 100644
--- a/clippy_dev/src/new_lint.rs
+++ b/clippy_dev/src/new_lint.rs
@@ -455,7 +455,7 @@ fn setup_mod_file(path: &Path, lint: &LintData<'_>) -> io::Result<&'static str>
     });
 
     // Find both the last lint declaration (declare_clippy_lint!) and the lint pass impl
-    while let Some(LintDeclSearchResult { content, .. }) = iter.find(|result| result.token == TokenKind::Ident) {
+    while let Some(LintDeclSearchResult { content, .. }) = iter.find(|result| result.token_kind == TokenKind::Ident) {
         let mut iter = iter
             .by_ref()
             .filter(|t| !matches!(t.token_kind, TokenKind::Whitespace | TokenKind::LineComment { .. }));
@@ -465,7 +465,7 @@ fn setup_mod_file(path: &Path, lint: &LintData<'_>) -> io::Result<&'static str>
                 // matches `!{`
                 match_tokens!(iter, Bang OpenBrace);
                 if let Some(LintDeclSearchResult { range, .. }) =
-                    iter.find(|result| result.token == TokenKind::CloseBrace)
+                    iter.find(|result| result.token_kind == TokenKind::CloseBrace)
                 {
                     last_decl_curly_offset = Some(range.end);
                 }