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
drchase@drchase01:/tmp$ go run bad.go
FAIL, *n should be 99, not 8
In the generated code from GOSSAFUNC='(*SessionsInfo).test' go run bad.go
notice how &n is moved to (SP) at line 22, then smashed at line 27 before the call to runtime.mapaccess1_faststr on line 32.
Here is another failing program believed to have the same cause (similar boolean-to-interface conversion, failure introduced at same commit): https://play.golang.org/p/-Rus8Xs1Ze
The text was updated successfully, but these errors were encountered:
ianlancetaylor
changed the title
Map lookup of boolean, then converted to interface{}, causes parameter smash
cmd/compile: map lookup of boolean, then converted to interface{}, causes parameter smash
Feb 24, 2017
Please answer these questions before submitting your issue. Thanks!
What version of Go are you using (
go version
)?I isolated the failing commit:
I.e., "cmd/compile: skip convT2E for empty structs"
What operating system and processor architecture are you using (
go env
)?linux/amd64
The test works in the playground, but fails using go devel at 8958d8c or later.
https://play.golang.org/p/8idlRKU3Q8
In the generated code from
GOSSAFUNC='(*SessionsInfo).test' go run bad.go
notice how &n is moved to (SP) at line 22, then smashed at line 27 before the call to
runtime.mapaccess1_faststr
on line 32.Here is another failing program believed to have the same cause (similar boolean-to-interface conversion, failure introduced at same commit): https://play.golang.org/p/-Rus8Xs1Ze
The text was updated successfully, but these errors were encountered: