Closed flimzy closed 8 years ago
As a general observation (outside the scope of this PR), @davecgh, you may want to consider using safe
build tag in place of disableunsafe
. It's shorter, simpler, and mirrors unsafe
nicely. It's the pattern people like Brad Fitzpatrick arrived at and used in a few high profile Go packages already.
Also, relevant to this PR, see this commit for some precedent:
Notice:
// +build js appengine safe
// +build !js,!appengine,!safe
@flimzy, I've left some inline comments about fixing documentation, but otherwise this LGTM.
Thanks for the PR. Looks good.
OK
@shurcooL: That seems very reasonable to me. As you mentioned it's shorter too. I don't really like breaking backwards compat like that, but now that the project was tagged and glide has become much more ubiquitous, that's not as big of an issue.
@davecgh: You can always support both the safe
and disableunsafe
build tags for a time (or even indefinitely) if backward compatibility of this feature is a big concern.
@flimzy. I merged in the safe
tag yesterday and that is exactly what I ended up doing.
This simple commit makes go-spew work with the GopherJS compiler.