mirror of
https://github.com/rust-lang/rust-clippy
synced 2024-11-22 04:33:15 +00:00
rustup
This commit is contained in:
parent
2703038f93
commit
467b1ad9a4
2 changed files with 4 additions and 4 deletions
|
@ -13,7 +13,7 @@ pub struct MiscPass;
|
|||
|
||||
|
||||
declare_lint!(CLIPPY_SINGLE_MATCH, Warn,
|
||||
"Warn on usage of matches with a single nontrivial arm")
|
||||
"Warn on usage of matches with a single nontrivial arm");
|
||||
|
||||
impl LintPass for MiscPass {
|
||||
fn get_lints(&self) -> LintArray {
|
||||
|
@ -47,7 +47,7 @@ impl LintPass for MiscPass {
|
|||
}
|
||||
|
||||
|
||||
declare_lint!(CLIPPY_STR_TO_STRING, Warn, "Warn when a String could use into_string() instead of to_string()")
|
||||
declare_lint!(CLIPPY_STR_TO_STRING, Warn, "Warn when a String could use into_string() instead of to_string()");
|
||||
|
||||
pub struct StrToStringPass;
|
||||
|
||||
|
|
|
@ -10,9 +10,9 @@ use syntax::codemap::Span;
|
|||
pub struct TypePass;
|
||||
|
||||
declare_lint!(CLIPPY_BOX_VEC, Warn,
|
||||
"Warn on usage of Box<Vec<T>>")
|
||||
"Warn on usage of Box<Vec<T>>");
|
||||
declare_lint!(CLIPPY_DLIST, Warn,
|
||||
"Warn on usage of DList")
|
||||
"Warn on usage of DList");
|
||||
|
||||
/// Matches a type with a provided string, and returns its type parameters if successful
|
||||
pub fn match_ty_unwrap<'a>(ty: &'a Ty, segments: &[&str]) -> Option<&'a [P<Ty>]> {
|
||||
|
|
Loading…
Reference in a new issue