Releases: crossoverJie/gscript
Releases · crossoverJie/gscript
v0.0.12
What's Changed
- semantic_resolver by @crossoverJie in #24
- ✨ compile check type. by @crossoverJie in #26
- fix #27 by @crossoverJie in #28
Full Changelog: v0.0.11...v0.0.12
v0.0.11
What's Changed
- support dump ast/symbol by @crossoverJie in #19
- 🐳 Work about Docker. by @crossoverJie in #20
- support byte by @crossoverJie in #21
Full Changelog: v0.0.10...v0.0.11
v0.0.10
What's Changed
- ✅ runtime msg by @crossoverJie in #17
Full Changelog: v0.0.9...v0.0.10
- Runtime msg
- New
System/DateTime
API
class DateTime{
string getCurrentTime(string tz, string layout){
return GetCurrentTime(tz, layout);
}
int unix(string tz){
return Unix(tz);
}
}
// system os api
class System{
// Get os args.
string[] getOSArgs(){
return GetOSArgs();
}
string command(string name, string ...arg){
return Command(name, arg);
}
// attention: perm is the decimal
writeFile(string fileName, string value, int perm){
WriteFile(fileName, value, perm);
}
// removes the named file
remove(string fileName){
Remove(fileName);
}
}
v0.0.9
What's Changed
- support variable parameters and printf() sprintf() by @crossoverJie in #15
- ✨ support compile error msg by @crossoverJie in #16
Full Changelog: v0.0.8...v0.0.9
example: print_triangle.gs
int num(int x,int y){
if (y==1 || y ==x) {
return 1;
}
int v1 = num(x - 1, y - 1);
int v2 = num(x - 1, y);
int c = v1+v2;
// int c = num(x - 1, y - 1)+num(x - 1, y);
return c;
}
printTriangle(int row){
for (int i = 1; i <= row; i++) {
for (int j = 1; j <= row - i; j++) {
print(" ");
}
for (int j = 1; j <= i; j++) {
print(num(i, j) + " ");
}
println("");
}
}
printTriangle(7);
1
1 1
1 2 1
1 3 3 1
1 4 6 4 1
1 5 10 10 5 1
1 6 15 20 15 6 1
v0.0.8
What's Changed
- support any by @crossoverJie in #6
- ✨ support JSON. by @crossoverJie in #7
- ✨ support HTTP lib. by @crossoverJie in #8
- ✨ add getOSArgs() function by @crossoverJie in #9
- example leetcode two sum by @crossoverJie in #10
Full Changelog: v0.0.7...v0.0.8
v0.0.7
v0.0.6
- Class
- Primitive(int/string/float/bool)
- nil type
- Standard lib: array/Map
- Closure