Rename the language from Dino to Rex
Files use .rex, the command is rex, and the crate, runtime prefixes, docs, editor files and examples all use the new name. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
2f44f09b6a
commit
7cf9727bcd
94 files changed
+858
-858
No files matched your search
@@ -4,7 +4,7 @@
|
||||
|
||||
No parentheses around the condition. The braces are required. The condition must be a `bool`.
|
||||
|
||||
```dino
|
||||
```rex
|
||||
func main() {
|
||||
var temp = 21
|
||||
if temp > 30 {
|
||||
@@ -26,7 +26,7 @@ Combine conditions with `&&`, `||` and `!`. The right side only runs when needed
|
||||
|
||||
There is one keyword for every kind of loop.
|
||||
|
||||
```dino
|
||||
```rex
|
||||
func main() {
|
||||
for i in 0..3 { // 0, 1, 2: the end is not included
|
||||
print("i =", i)
|
||||
@@ -83,7 +83,7 @@ the loop is safe.
|
||||
`match` picks a branch by shape. It must cover every possibility, otherwise the compiler
|
||||
lists what is missing. `_` means "anything else".
|
||||
|
||||
```dino
|
||||
```rex
|
||||
enum Shape {
|
||||
Circle(r: float)
|
||||
Rect(w, h: float)
|
||||
@@ -119,7 +119,7 @@ zero one many
|
||||
`match` works on enums, ints, bools and strings. Used as a **value** (like above) each arm
|
||||
is one expression. Used as a **statement** an arm can be a block:
|
||||
|
||||
```dino
|
||||
```rex
|
||||
func main() {
|
||||
var cmd = "stop"
|
||||
match cmd {
|
||||
|
||||
Reference in new issue
Block a user