mirror of
https://github.com/krgamestudios/Toy.git
synced 2026-04-15 14:54:07 +10:00
Added ternary operator
This commit is contained in:
@@ -192,7 +192,7 @@ The following mathematical operators are available. A definition is omitted here
|
||||
Likewise, the following logical operators are available (`&&` is more tightly bound than `||` due to historical reasons):
|
||||
|
||||
```
|
||||
( ) [ ] { } ! != == < > <= >= && ||
|
||||
( ) [ ] { } ! != == < > <= >= && || ?:
|
||||
```
|
||||
|
||||
Other operators used throughout the language are: the assignment, colon, semicolon, comma, dot and rest operators:
|
||||
|
||||
@@ -24,7 +24,7 @@ Some things I'd like to add in the future include:
|
||||
* A random generation library (numbers, perlin noise, wave function collapse?)
|
||||
* A timer library (under development)
|
||||
* Multiple return values from functions
|
||||
* Ternary operator
|
||||
* ~~Ternary operator~~
|
||||
* interpolated strings
|
||||
|
||||
Some of these have always been planned, but were sidelined or are incomplete for one reason or another.
|
||||
|
||||
Reference in New Issue
Block a user