You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If the a field becomes exported. Then it is not panic. But the rule of unexported fields from different packages are always viewed as fields with different names is only for defined struct types.
Aha, looks the rule also applies for non-defined struct types. That is a good news.
So this is a bug of 1.7-. 1.7- compilers don't panic the program but they should.
What version of Go are you using (
go version
)?go version go1.9.2 linux/amd6
Does this issue reproduce with the latest release?
Yes. This is broken since go 1.8.
What did you do?
package
m
:package
main
:What did you expect to see?
Not panic
What did you see instead?
Panic.
The text was updated successfully, but these errors were encountered: