Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
cmd/compile: <autogenerated>:1: symbol listed multiple times for same type across multiple packages #31252
Different packages and same struct function compile error
go version go1.12.1 windows/amd64
this problem happeded in version go1.12, my test in version go1.11 is ok. I think this is compile bug.
I have a fix.
@cuonglm Yes, it's pretty cryptic.
This part of the compiler really needs better documentation. It confuses me every time I look at it also...
Both types.Sym and obj.LSym have the field Name, and that field is widely used in compiler source. It can lead to confusion that when to use which one. So, adding documentation for clarifying the difference between them, eliminate the confusion, or at least, make the code which use them clearer for the reader. See #31252 (comment) Change-Id: I31f7fc6e4de4cf68f67ab2e3a385a7f451c796f5 Reviewed-on: https://go-review.googlesource.com/c/go/+/175019 Reviewed-by: Keith Randall <firstname.lastname@example.org> Reviewed-by: Matthew Dempsky <email@example.com>