cgo: add file AST for fake C file locations

This is needed for the type checker, otherwise it doesn't know which Go
version it should use for type checking.
This commit is contained in:
Ayke van Laethem
2024-01-17 15:55:07 +01:00
parent 0ad15551c8
commit 53db436a7d
5 changed files with 38 additions and 6 deletions
+1 -1
View File
@@ -447,7 +447,7 @@ func (p *Package) parseFiles() ([]*ast.File, error) {
if errs != nil {
fileErrs = append(fileErrs, errs...)
}
files = append(files, generated)
files = append(files, generated...)
p.program.LDFlags = append(p.program.LDFlags, ldflags...)
}