diff --git a/bind/gencpy_func.go b/bind/gencpy_func.go index 6c2c7e9..9a25dfd 100644 --- a/bind/gencpy_func.go +++ b/bind/gencpy_func.go @@ -285,8 +285,8 @@ func (g *cpyGen) genFuncBody(f Func) { } g.impl.Printf("cgopy_seq_send(%q, %d, ibuf->buf, ibuf->len, &obuf->buf, &obuf->len);\n\n", - g.pkg.ImportPath()+"."+f.GoName(), - uhash(f.GoName()), + f.Package().ImportPath()+"."+f.GoName(), + uhash(f.ID()), ) if len(res) <= 0 { diff --git a/bind/gengo.go b/bind/gengo.go index 45c0478..ae3feee 100644 --- a/bind/gengo.go +++ b/bind/gengo.go @@ -163,8 +163,8 @@ func cgo_func_%[1]s(out, in *seq.Buffer) { g.Printf("}\n\n") g.regs = append(g.regs, goReg{ - Descriptor: g.pkg.ImportPath() + "." + f.GoName(), - ID: uhash(f.GoName()), + Descriptor: f.Package().ImportPath() + "." + f.GoName(), + ID: uhash(f.ID()), Func: f.ID(), }) }