Move renaming to the right place

This commit is contained in:
flip1995
2018-12-17 13:58:41 +01:00
parent 355018d086
commit 0516c2e04a
2 changed files with 4 additions and 1 deletions

View File

@@ -1028,8 +1028,10 @@ pub fn register_plugins(reg: &mut rustc_plugin::Registry<'_>, conf: &Conf) {
unwrap::PANICKING_UNWRAP, unwrap::PANICKING_UNWRAP,
unwrap::UNNECESSARY_UNWRAP, unwrap::UNNECESSARY_UNWRAP,
]); ]);
}
store.register_renamed("stutter", "module_name_repeat"); pub fn register_renamed(ls: &mut rustc::lint::LintStore) {
ls.register_renamed("clippy::stutter", "clippy::module_name_repeat");
} }
// only exists to let the dogfood integration test works. // only exists to let the dogfood integration test works.

View File

@@ -110,6 +110,7 @@ pub fn main() {
ls.register_group(Some(sess), true, name, deprecated_name, to); ls.register_group(Some(sess), true, name, deprecated_name, to);
} }
clippy_lints::register_pre_expansion_lints(sess, &mut ls, &conf); clippy_lints::register_pre_expansion_lints(sess, &mut ls, &conf);
clippy_lints::register_renamed(&mut ls);
sess.plugin_llvm_passes.borrow_mut().extend(llvm_passes); sess.plugin_llvm_passes.borrow_mut().extend(llvm_passes);
sess.plugin_attributes.borrow_mut().extend(attributes); sess.plugin_attributes.borrow_mut().extend(attributes);