From 1c681b6ab63fabae44f28c1cb6dfb31319d27d77 Mon Sep 17 00:00:00 2001 From: Michael Wright Date: Thu, 16 Aug 2018 07:13:52 +0200 Subject: [PATCH] fix-2927: Update formatting --- clippy_lints/src/lib.rs | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/clippy_lints/src/lib.rs b/clippy_lints/src/lib.rs index 680ff2c9600..3de7c6de979 100644 --- a/clippy_lints/src/lib.rs +++ b/clippy_lints/src/lib.rs @@ -179,6 +179,14 @@ mod reexport { crate use syntax::ast::{Name, NodeId}; } +pub fn register_pre_expansion_lints(session: &rustc::session::Session, store: &mut rustc::lint::LintStore, conf: &Conf) { + store.register_pre_expansion_pass(Some(session), box write::Pass); + store.register_pre_expansion_pass(Some(session), box redundant_field_names::RedundantFieldNames); + store.register_pre_expansion_pass(Some(session), box non_expressive_names::NonExpressiveNames { + single_char_binding_names_threshold: conf.single_char_binding_names_threshold, + }); +} + pub fn read_conf(reg: &rustc_plugin::Registry<'_>) -> Conf { match utils::conf::file_from_args(reg.args()) { Ok(file_name) => { @@ -225,14 +233,6 @@ pub fn read_conf(reg: &rustc_plugin::Registry<'_>) -> Conf { } } -pub fn register_pre_expansion_lints(session: &rustc::session::Session, store: &mut rustc::lint::LintStore, conf: &Conf) { - store.register_pre_expansion_pass(Some(session), box write::Pass); - store.register_pre_expansion_pass(Some(session), box redundant_field_names::RedundantFieldNames); - store.register_pre_expansion_pass(Some(session), box non_expressive_names::NonExpressiveNames { - single_char_binding_names_threshold: conf.single_char_binding_names_threshold, - }); -} - #[rustfmt::skip] pub fn register_plugins(reg: &mut rustc_plugin::Registry<'_>, conf: &Conf) { let mut store = reg.sess.lint_store.borrow_mut();