diff options
| author | DanielGavin <danielgavin5@hotmail.com> | 2020-12-18 15:09:30 +0100 |
|---|---|---|
| committer | DanielGavin <danielgavin5@hotmail.com> | 2020-12-18 15:09:30 +0100 |
| commit | bf9e093d9f4f0d5aaa6cd14d751a3ba6f775bf00 (patch) | |
| tree | 96179b015b114ca0ac56b63d68d425dd11108d22 /src/index | |
| parent | 53887066c915c0e332871c867beb500fd8b407e9 (diff) | |
fixed crash after updating Odin
Diffstat (limited to 'src/index')
| -rw-r--r-- | src/index/build.odin | 6 |
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); |