Skip to content

nonsense help message for stray => #35907

Closed
@durka

Description

@durka

Code:

if true => { }

Output:

error: expected `{`, found `=>`
 --> expr.rs:5:10
  |
5 | if true => { }
  |         ^^
  |
  = help: place this code inside a block

"Place this code inside a block" doesn't make any sense here.

Metadata

Metadata

Assignees

Labels

A-diagnosticsArea: Messages for errors, warnings, and lintsA-parserArea: The lexing & parsing of Rust source code to an AST

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions