aboutsummaryrefslogtreecommitdiff
path: root/src/index
diff options
context:
space:
mode:
authorDanielGavin <danielgavin5@hotmail.com>2020-12-18 15:09:30 +0100
committerDanielGavin <danielgavin5@hotmail.com>2020-12-18 15:09:30 +0100
commitbf9e093d9f4f0d5aaa6cd14d751a3ba6f775bf00 (patch)
tree96179b015b114ca0ac56b63d68d425dd11108d22 /src/index
parent53887066c915c0e332871c867beb500fd8b407e9 (diff)
fixed crash after updating Odin
Diffstat (limited to 'src/index')
-rw-r--r--src/index/build.odin6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/index/build.odin b/src/index/build.odin
index bf1536a..890de2b 100644
--- a/src/index/build.odin
+++ b/src/index/build.odin
@@ -59,9 +59,15 @@ build_static_index :: proc(allocator := context.allocator, config: ^common.Confi
warn = no_warning_handler,
};
+ //have to cheat the parser since it really wants to parse an entire package with the new changes...
+ pkg := new(ast.Package);
+ pkg.kind = .Normal;
+ pkg.fullpath = fullpath;
+
file := ast.File {
fullpath = fullpath,
src = data,
+ pkg = pkg,
};
ok = parser.parse_file(&p, &file);