compiler: emit bytecode for unused exported functions
Exported functions should always be present in byte-code. This will be needed later when arbitrary method calls are allowed.
This commit is contained in:
parent
54d7882acf
commit
e87eba51f9
2 changed files with 8 additions and 2 deletions
|
@ -1426,7 +1426,7 @@ func (c *codegen) compile(info *buildInfo, pkg *loader.PackageInfo) error {
|
|||
return c.prog.Err
|
||||
}
|
||||
|
||||
funUsage := analyzeFuncUsage(info.program.AllPackages)
|
||||
funUsage := analyzeFuncUsage(pkg, info.program.AllPackages)
|
||||
|
||||
// Bring all imported functions into scope.
|
||||
for _, pkg := range info.program.AllPackages {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue