mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-26 08:44:35 +00:00
fix-2927: Update formatting
This commit is contained in:
parent
bbd67c9b78
commit
1c681b6ab6
@ -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();
|
||||
|
Loading…
Reference in New Issue
Block a user