mirror of
https://github.com/wren-lang/wren.git
synced 2026-01-16 20:28:04 +01:00
Allow infix () and {} to call "call" on the left-hand side.
- Allow this for both argument lists and block arguments.
- Tweak precedence to make "." higher than infix "{}" to avoid a
class body being parsed as the superclass clause's block argument.
- Convert all uses of ".call" to use this. (There was not a single
case in the repo that ran into the getter ambiguity.)
This commit is contained in:
@ -14,5 +14,5 @@ System.print(variable) // expect: method
|
||||
|
||||
Fn.new {
|
||||
variable = "fn"
|
||||
}.call()
|
||||
}()
|
||||
System.print(variable) // expect: fn
|
||||
|
||||
Reference in New Issue
Block a user