Misc cleanups, simplifications, style, and doc fixes.
Merge pull request #6 from bradfitz/hex

Misc cleanups, simplifications, style, and doc fixes.