bytes: hoist error creation out of function
bytes: hoist error creation out of function

generating frame information in errors will cause this
function to no longer be inlined.

Updates #29934.

Change-Id: I1d7bc11707f1872d7315f627bfb9a12afa41e358
Reviewed-on: https://go-review.googlesource.com/c/161760
Run-TryBot: Marcel van Lohuizen <a22d082192f3ccf984644a4f482781f4c2d65180@golang.org>
TryBot-Result: Gobot Gobot <66cb808b70d30c07676d5e946fee83fd561249e5@golang.org>
Reviewed-by: Russ Cox <5ad239cb8a44f659eaaee0aa1ea5b94947abe557@golang.org>
Reviewed-by: Brad Fitzpatrick <ae9783c0b0efc69cd85ab025ddd17aa44cdc4aa5@golang.org>

golang/go,CAFxX/go,cloudflare/go,josharian/go,cloudflare/go,CAFxX/go,josharian/go,CAFxX/go,cloudflare/go,nawawi/go,nawawi/go,CAFxX/go,akutz/go,cloudflare/go,akutz/go,CAFxX/go,nawawi/go,golang/go,josharian/go,akutz/go,nawawi/go,golang/go,CAFxX/go,josharian/go,nawawi/go,golang/go,josharian/go,akutz/go,akutz/go,akutz/go,cloudflare/go,nawawi/go,nawawi/go,golang/go,CAFxX/go,akutz/go,akutz/go,nawawi/go,CAFxX/go,cloudflare/go,golang/go,josharian/go,golang/go,cloudflare/go,josharian/go,golang/go,josharian/go,cloudflare/go