More work on grammer and standard library! It can kinda load grammer now! Kinda. Marcus ran into the function pointer returns pointer ambiguity, so that'll have to be done tomorrow.
This commit is contained in:
1 parent
b62c3e729f
commit
54721b4284
11 files changed
+149
-4
No files matched your search
@@ -0,0 +1,4 @@
|
||||
# comment
|
||||
a = b ;
|
||||
b = "c" ;
|
||||
b = "c" "d" ;
|
||||
+28
-1
@@ -1,7 +1,34 @@
|
||||
import io
|
||||
import io: something
|
||||
|
||||
//comments
|
||||
|
||||
fun first(): cutomTye {
|
||||
}
|
||||
fun another(): cutomTye<hello, beta>* {
|
||||
|
||||
}
|
||||
|
||||
fun main():int {
|
||||
if (true) {
|
||||
thing;
|
||||
}
|
||||
if ( 3 < 300) {
|
||||
}
|
||||
if ( 3 > 300) {
|
||||
}
|
||||
var hastype: type = 20
|
||||
thingy.other;
|
||||
if ( 3 < 300) {
|
||||
}
|
||||
io::print("hi")
|
||||
wanna.callit(internal, to ,it)
|
||||
var a = 2 + 7;
|
||||
var b = 2 + 7 / 3 - 2 * 7 && 9 || 2 + !g
|
||||
return 0
|
||||
return 11820
|
||||
return 1.1
|
||||
return 1.1f
|
||||
return "hi"
|
||||
}
|
||||
|
||||
|
||||
@@ -0,0 +1,11 @@
|
||||
import io:*
|
||||
import grammer:*
|
||||
import string:*
|
||||
|
||||
fun main():int {
|
||||
var a = load_grammer(string("grammer.kgm"))
|
||||
println(a.to_string())
|
||||
return 0
|
||||
}
|
||||
|
||||
|
||||
@@ -0,0 +1,6 @@
|
||||
|
||||
fun main():int {
|
||||
var wr: fun():int*
|
||||
return 0
|
||||
}
|
||||
|
||||
@@ -9,3 +9,5 @@ a
|
||||
now win!
|
||||
true
|
||||
false
|
||||
2
|
||||
lines
|
||||
@@ -22,6 +22,7 @@ fun main(): int {
|
||||
io::println(newWay)
|
||||
io::println( string::string("yes") == string::string("yes") )
|
||||
io::println( string::string("no") == string::string("yes") )
|
||||
string::string("2\nlines").lines().for_each(fun(i: string::string) io::println(i);)
|
||||
return 0;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user