amr-lang 1.0.7 → 1.0.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -104,9 +104,9 @@ when age > 21 {
104
104
  }
105
105
 
106
106
  # Arabic version
107
- اذا age > 17 {
107
+ لو age > 17 {
108
108
  اطبع 1
109
- } والا {
109
+ } لولا {
110
110
  اطبع 0
111
111
  }
112
112
  ```
@@ -149,8 +149,8 @@ show 10 # Inline comment
149
149
  - `اطبع` - Print output (show)
150
150
  - `اعمل` - Function declaration (make)
151
151
  - `رجع` - Return from function (return)
152
- - `اذا` - If statement (when)
153
- - `والا` - Else statement (otherwise)
152
+ - `لو` - If statement (when)
153
+ - `لولا` - Else statement (otherwise)
154
154
  - `كرر` - While loop (loop)
155
155
 
156
156
  ## Example Programs
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "amr-lang",
3
- "version": "1.0.7",
3
+ "version": "1.0.8",
4
4
  "description": "A simple programming language with bilingual support (English & Arabic)",
5
5
  "author": "amrelsherbiny",
6
6
  "license": "MIT",
package/src/lexer.ts CHANGED
@@ -12,8 +12,8 @@ const arabicKeywords: Record<string, string> = {
12
12
  "اطبع": "SHOW",
13
13
  "اعمل": "MAKE",
14
14
  "رجع": "RETURN",
15
- "اذا": "WHEN",
16
- "والا": "OTHERWISE",
15
+ "لو": "WHEN",
16
+ "لولا": "OTHERWISE",
17
17
  "كرر": "LOOP"
18
18
  };
19
19