Starting to really parse! Fixed the bad syntax trees (reduction copy_construct wasn't actually copying label because param and dest had same name) and fixed the krakenGrammer and CGenerator to allow escaped quotes in regular strings. add_children needs to be finished so the resulting trees don't go nuts with ambiguity, and some situations still cause vector access errors, which is odd. Also added the crazy simple write_file to io and the test_grammer.krak now outputs a syntax_tree.dot

This commit is contained in:
Nathan Braswell
2015-08-11 01:07:16 -04:00
parent 2777ca10f1
commit 58ab3e311f
6 changed files with 66 additions and 26 deletions

View File

@@ -6,6 +6,11 @@ fun string(in:*char):string {
var out.construct(in):string
return out
}
fun string(in:char):string {
var out.construct():string
out += in
return out
}
obj string (Object) {
var data: vector::vector<char>;