pxeger / whython

Fork of Python with some terrible custom features hacked in
https://www.pxeger.com/2021-09-19-hacking-on-cpython/
Other
16 stars 3 forks source link

Unary ++ operator #11

Open pxeger opened 2 years ago

pxeger commented 2 years ago

An expression x++ would be equivalent to (x := x + 1).

chunkybanana commented 2 years ago

Cool, but gonna be very hard to do without rewriting the parser. (afaik) Python has no postfix operators normally.

Also, how are you gonna distinguish it from a+ +b?