Open GreasySlug opened 1 year ago
This is not a bug, but an associative order of anonymous function operators.
i = (x, y): Int -> x + y
The above code is interpreted as follows.
i = (x, y): (Int -> x + y)
I'm aware that this is not natural, but I didn't fix it because I could just wrap it in ()
.
Ah, before that, it seems that the anonymous function operator cannot recognize the return type.
Describe the bug?
Error occurs when return value is specified of anonymous function
edit: the anonymous function operator cannot recognize the return type.
Reproducible code
Expected result
No error
Actual result
Additional context
No response
Erg version
Erg 0.6.2-nightly.0
Python version
Python3.11.x
OS
Windows 10