Skip to content
Open
Changes from 1 commit
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
4 changes: 2 additions & 2 deletions docs/empty-statement-syntax.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,9 +58,9 @@ As already is the case, empty statements have no impact in generated bytecode.

## Drawbacks

Previously erroring code would now be valid, though uses of Luau relying on this error would be exceptionally rare (and admittedly odd).
Previously erroring code would now parse. This is not considered to be a problem, as such programs were never valid in the first place.

Luau is designed to be backwards compatible with Lua 5.1, and adopting this syntax would diverge from that compatibility. However, Luau already diverges from Lua 5.1's syntax, and this change would align Luau more closely with modern Lua.
This syntax, when used, is not backwards-compatible. However, it can easily be removed without changing the meaning of code (which isn't the case for many other syntax features introduced by Luau).

This syntax addition technically allows for unusual "ugly" code such as:

Expand Down