We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Attempting to bind
package p type I interface { f() }
fails to compile with
go_pmain.go:20: v.f undefined (cannot refer to unexported field or method f)
The problem is the bind code generates a proxy implementation of the interface I, which is impossible:
type proxyI seq.Ref func (p *proxyI) f() { in := new(seq.Buffer) seq.Transact((*seq.Ref)(p), "go.p.I", proxyI_f_Code, in) }
For types like this we need to avoid generating a proxy.
The text was updated successfully, but these errors were encountered:
I'm going to start with the reasonable restriction:
and the overly broad restriction:
The second is overly broad because in Go a package can declare
package p func F() unexported func G(u unexported)
and then another package can call p.G(p.F()). But we can relax that later.
p.G(p.F())
/cc @hyangah
Sorry, something went wrong.
CL https://golang.org/cl/13946 mentions this issue.
golang/mobile@4628c38
bind: handle unimplementable interfaces
0415448
Fixes golang/go#12330 Change-Id: I1568d04b7e48242105a7028ca471e2138f684eeb Reviewed-on: https://go-review.googlesource.com/13946 Reviewed-by: Hyang-Ah Hana Kim <hyangah@gmail.com>
f562b75
No branches or pull requests
Attempting to bind
fails to compile with
The problem is the bind code generates a proxy implementation of the interface I, which is impossible:
For types like this we need to avoid generating a proxy.
The text was updated successfully, but these errors were encountered: