Rollup merge of #68981 - estebank:silence, r=davidtwco
Account for type params on method without parentheses Account for those type parameters in the structured suggestion when forgetting to call method: ``` error[E0615]: attempted to take value of method `collect` on type `std::vec::IntoIter<_>` --> $DIR/method-missing-parentheses.rs:2:32 | LL | let _ = vec![].into_iter().collect::<usize>; | ^^^^^^^--------- | | | help: use parentheses to call the method: `collect::<usize>()` ```
This commit is contained in:
commit
2a3c1a30c8
7 changed files with 44 additions and 14 deletions
|
|
@ -823,7 +823,7 @@ impl<'a> Parser<'a> {
|
|||
if let Some(args) = segment.args {
|
||||
self.struct_span_err(
|
||||
args.span(),
|
||||
"field expressions may not have generic arguments",
|
||||
"field expressions cannot have generic arguments",
|
||||
)
|
||||
.emit();
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue