https://github.com/iwhitebird/gor
Gor : Programming language made with GoLang
https://github.com/iwhitebird/gor
compiler-design go golang gor programming programming-language programming-languages
Last synced: 10 months ago
JSON representation
Gor : Programming language made with GoLang
- Host: GitHub
- URL: https://github.com/iwhitebird/gor
- Owner: IWhitebird
- License: mit
- Created: 2024-01-11T20:41:53.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2024-03-10T10:48:53.000Z (almost 2 years ago)
- Last Synced: 2025-01-22T22:17:18.813Z (12 months ago)
- Topics: compiler-design, go, golang, gor, programming, programming-language, programming-languages
- Language: Go
- Homepage: https://gorlang.vercel.app/
- Size: 5.02 MB
- Stars: 3
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README

# Gor Language
Gor is interpreted programming langauge made with Golang. It has similar syntax to that of JavaScript.
## Data types:
- Language has 5 datatypes: number, string, null, object, array.
## Variable declaration (static and non-static):
```
let a = 10
const b = ""
```
## Print statement:
```
print(a)
```
## Arithmetic operators & logical operators:
```
+, - , *, / , &, |
```
## Comparison operators:
```
==, <=, >=, !=, &&, ||
```
## Array and object declaration:
```
let a = [10, 2]
print(a[0])
const b = {
hi: 10
}
print(b.hi)
```
## Function declaration:
- Functions can be declared using `fn` keyword
```
fn myFunc(a, b) {
return a + b
}
myFunc(10, 20)
```
## Loops:
- Currently, the only loop Gor supports is the for loop.
```
for (let i = 0; i < 10; i = i + 1) {
print(i)
}
```
## Future Updates:
- While loop
- Unary operators (`--`, `++`)
- Multithreading