mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-27 17:24:06 +00:00
review comment: wording
This commit is contained in:
parent
97d47a5e7c
commit
9d91489526
@ -828,7 +828,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();
|
||||
}
|
||||
|
@ -9,9 +9,9 @@ fn main() {
|
||||
y: 2,
|
||||
};
|
||||
f.x::<isize>;
|
||||
//~^ ERROR field expressions may not have generic arguments
|
||||
//~^ ERROR field expressions cannot have generic arguments
|
||||
f.x::<>;
|
||||
//~^ ERROR field expressions may not have generic arguments
|
||||
//~^ ERROR field expressions cannot have generic arguments
|
||||
f.x::();
|
||||
//~^ ERROR field expressions may not have generic arguments
|
||||
//~^ ERROR field expressions cannot have generic arguments
|
||||
}
|
||||
|
@ -1,16 +1,16 @@
|
||||
error: field expressions may not have generic arguments
|
||||
error: field expressions cannot have generic arguments
|
||||
--> $DIR/type-parameters-in-field-exprs.rs:11:10
|
||||
|
|
||||
LL | f.x::<isize>;
|
||||
| ^^^^^^^
|
||||
|
||||
error: field expressions may not have generic arguments
|
||||
error: field expressions cannot have generic arguments
|
||||
--> $DIR/type-parameters-in-field-exprs.rs:13:10
|
||||
|
|
||||
LL | f.x::<>;
|
||||
| ^^
|
||||
|
||||
error: field expressions may not have generic arguments
|
||||
error: field expressions cannot have generic arguments
|
||||
--> $DIR/type-parameters-in-field-exprs.rs:15:7
|
||||
|
|
||||
LL | f.x::();
|
||||
|
@ -1,5 +1,5 @@
|
||||
fn main() {
|
||||
let _ = vec![].into_iter().collect::<usize>;
|
||||
//~^ ERROR attempted to take value of method `collect` on type `std::vec::IntoIter<_>`
|
||||
//~| ERROR field expressions may not have generic arguments
|
||||
//~| ERROR field expressions cannot have generic arguments
|
||||
}
|
||||
|
@ -1,4 +1,4 @@
|
||||
error: field expressions may not have generic arguments
|
||||
error: field expressions cannot have generic arguments
|
||||
--> $DIR/method-missing-parentheses.rs:2:41
|
||||
|
|
||||
LL | let _ = vec![].into_iter().collect::<usize>;
|
||||
|
Loading…
Reference in New Issue
Block a user