Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix typo in error message. #63530

Merged
merged 2 commits into from
Aug 14, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/libsyntax/parse/parser/expr.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1199,7 +1199,7 @@ impl<'a> Parser<'a> {
if self.eat_keyword(kw::Else) || !cond.returns() {
let sp = self.sess.source_map().next_point(lo);
let mut err = self.diagnostic()
.struct_span_err(sp, "missing condition for `if` statemement");
.struct_span_err(sp, "missing condition for `if` expression");
err.span_label(sp, "expected if condition here");
return Err(err)
}
Expand Down
4 changes: 2 additions & 2 deletions src/test/ui/issues/issue-13483.stderr
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
error: missing condition for `if` statemement
error: missing condition for `if` expression
--> $DIR/issue-13483.rs:3:14
|
LL | } else if {
| ^ expected if condition here

error: missing condition for `if` statemement
error: missing condition for `if` expression
--> $DIR/issue-13483.rs:10:14
|
LL | } else if {
Expand Down