mirror of
https://github.com/rust-lang/rust-analyzer
synced 2024-11-10 23:24:29 +00:00
nonminimal_bool
This commit is contained in:
parent
e58b683201
commit
e6f9f4c0e4
3 changed files with 2 additions and 3 deletions
|
@ -177,7 +177,6 @@ format_collect = "allow"
|
|||
large_enum_variant = "allow"
|
||||
needless_doctest_main = "allow"
|
||||
new_without_default = "allow"
|
||||
nonminimal_bool = "allow"
|
||||
non_canonical_clone_impl = "allow"
|
||||
non_canonical_partial_ord_impl = "allow"
|
||||
non_minimal_cfg = "allow"
|
||||
|
|
|
@ -100,7 +100,7 @@ fn validate_type_recursively(
|
|||
}
|
||||
(_, Some(ty)) => match ty.as_builtin() {
|
||||
// `const A: str` is not correct, but `const A: &builtin` is.
|
||||
Some(builtin) if refed || (!refed && !builtin.is_str()) => Some(()),
|
||||
Some(builtin) if refed || !builtin.is_str() => Some(()),
|
||||
_ => None,
|
||||
},
|
||||
_ => None,
|
||||
|
|
|
@ -23,7 +23,7 @@ impl ActiveParameter {
|
|||
|
||||
let idx = active_parameter?;
|
||||
let mut params = signature.params(sema.db);
|
||||
if !(idx < params.len()) {
|
||||
if idx >= params.len() {
|
||||
cov_mark::hit!(too_many_arguments);
|
||||
return None;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue