]> Cypherpunks repositories - gostls13.git/commit
cmd/compile: properly handle map assignments for OAS2DOTTYPE
authorTal Shprecher <tshprecher@gmail.com>
Thu, 5 May 2016 22:14:08 +0000 (15:14 -0700)
committerMatthew Dempsky <mdempsky@google.com>
Sat, 7 May 2016 08:00:39 +0000 (08:00 +0000)
commit9d7c9b4384db01afd2acb27d3a4636b60e957f08
tree0a1ef1190dccddaf64bec8682f76ce0791777adb
parente6ec82067a9068c93db6e7041017060a1c863452
cmd/compile: properly handle map assignments for OAS2DOTTYPE

The boolean destination in an OAS2DOTTYPE expression craps out during
compilation when trying to assign to a map entry because, unlike slice entries,
map entries are not directly addressable in memory. The solution is to
properly order the boolean destination node so that map entries are set
via autotmp variables.

Fixes #14678

Change-Id: If344e8f232b5bdac1b53c0f0d21eeb43ab17d3de
Reviewed-on: https://go-review.googlesource.com/22833
Reviewed-by: Matthew Dempsky <mdempsky@google.com>
Run-TryBot: Matthew Dempsky <mdempsky@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
src/cmd/compile/internal/gc/order.go
test/fixedbugs/issue14678.go [new file with mode: 0644]