Copy of go plugin from go-1.3