R=golang-dev, alex.brainman, minux.ma CC=golang-dev https://golang.org/cl/6443110
Fixes #364. R=ken2 https://golang.org/cl/164092