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
Code: ------------------------------------------------------------- package main type MyInterface interface { } type My struct { a, b, c int } var my = &My{1,2,3} var myInterface MyInterface = my var origMy, ok = myInterface.(*My) func main() { } ------------------------------------------------------------- Compilation gives: ------------------------------------------------------------- [nsf @ waytogo]$ 8g test.go defn [9f9cbc0] . AS2DOTTYPE l(12) x(-1000000000) tc(1) . AS2DOTTYPE-list . . NAME-origMy G0 u(1) a(1) l(12) class(1) tc(1) *My . . NAME-ok G0 u(1) a(1) l(12) class(1) tc(1) bool . AS2DOTTYPE-rlist . . DOTTYPE2 l(12) x(-1000000000) tc(1) *My . . . NAME-myInterface G0 u(1) a(1) l(11) class(1) tc(1) MyInterface test.go:15: internal compiler error: init1: bad defn ------------------------------------------------------------- Compiler/machine spec: linux, 386, b761e0299e9b release/release.2010-07-01 Even if it's not a legal declaration, good error message is expected.
The text was updated successfully, but these errors were encountered:
Comment 1:
Labels changed: added compilerbug.
Owner changed to r...@golang.org.
Status changed to Accepted.
Sorry, something went wrong.
Comment 2:
This issue was closed by revision 08a263a.
Status changed to Fixed.
No branches or pull requests
The text was updated successfully, but these errors were encountered: