]> Cypherpunks repositories - gostls13.git/commit
cmd/compile: cull dead code
authorJosh Bleecher Snyder <josharian@gmail.com>
Sat, 10 Nov 2018 14:58:36 +0000 (06:58 -0800)
committerDaniel Martí <mvdan@mvdan.cc>
Tue, 26 Feb 2019 18:37:19 +0000 (18:37 +0000)
commit01971b97c11cd55e9e65f628b7f1c3fc8ef81944
tree3e5c95cf1d9c979bca48c60b8d77e8f45ca7104b
parent8ca559eed5a5b87cb4a1ebe29c95b47aa723151e
cmd/compile: cull dead code

The special case for ODOTPTR to handle zero-width fields is unneeded.
It is an artifact of the old backend, from which time this code dates.
The Node to SSA converter is careful to insert a nil check.
This is tested in test/nilptr2.go, among other places.

Passes toolstash-check.

Change-Id: I6c1d99f7ff5abdae9aa08ee047dc088a3fe8dc3c
Reviewed-on: https://go-review.googlesource.com/c/148828
Run-TryBot: Josh Bleecher Snyder <josharian@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Matthew Dempsky <mdempsky@google.com>
src/cmd/compile/internal/gc/walk.go