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
Does this issue reproduce with the latest release?
yes
What did you do?
package main
funcmain() {
varaint64switcha {
caseint64(123):
caseint32(123):
}
}
What did you see instead?
gc reports:
./aa.go:7:2: invalid case int32(123) in switch on a (mismatched types int32 and int64)
./aa.go:7:2: duplicate case int32(123) (value 123) in switch
previous case at ./aa.go:6:12
Although it is not a big problem, I think the second error message is not very necessary, for it implies int32(123) is comparable to int64(123). (gccgo doesn't report the second error)
The text was updated successfully, but these errors were encountered:
What version of Go are you using (
go version
)?go version go1.11.1 linux/amd64
Does this issue reproduce with the latest release?
yes
What did you do?
What did you see instead?
gc reports:
Although it is not a big problem, I think the second error message is not very necessary, for it implies int32(123) is comparable to int64(123). (gccgo doesn't report the second error)
The text was updated successfully, but these errors were encountered: