nucleus-lang / nucleus-old

The Old Version of Nucleus (saved in here just in case)
7 stars 0 forks source link

Math: Add "-" unary operator to initialize negative numbers. #10

Closed TheNachoBIT closed 1 year ago

TheNachoBIT commented 1 year ago

At the moment, because there's no "-" unary operator, in order to initialize an integer as "-11", you have to code it like this:

var someInteger: int = 0 - 11;

Otherwise, it'll throw an:

Error: Unknown binary operator - if you initialize it as "-11".