The heuristic to generate a package name identifier was incorrect. Now for binary packages, the package identifier is obtained by a symbol, generated by extract, which contains the string argument of package statement in source file. This should ensure an always correct default package identifier. Fixes #1095.
18 lines
541 B
Go
18 lines
541 B
Go
// +build go1.14
|
|
|
|
// Package syscall provide wrapper of standard library syscall package for native import in Yaegi.
|
|
package syscall
|
|
|
|
import "reflect"
|
|
|
|
// Symbols stores the map of syscall package symbols.
|
|
var Symbols = map[string]map[string]reflect.Value{}
|
|
|
|
func init() {
|
|
Symbols["github.com/traefik/yaegi/stdlib/syscall/syscall"] = map[string]reflect.Value{
|
|
"Symbols": reflect.ValueOf(Symbols),
|
|
}
|
|
}
|
|
|
|
//go:generate ../../internal/cmd/extract/extract -exclude=^Exec,Exit,ForkExec,Kill,Ptrace,Reboot,Shutdown,StartProcess,Syscall syscall
|