Skip to content

Make set keyword optional and include lint to suggest avoiding it. #1496

@swernli

Description

@swernli

The set and let keywords are very similar and easy to confuse, leading to accidental shadowing sometimes. In addition, let is already sufficient to disambiguate declaration/binding from assignment, so set doesn't provide any actual value syntactically. We can leave the keyword in but make it optional in the parser, and then later follow up with a lint rule about it.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions