types: enforce consistent type checking
Wallet: use enforceType where applicable
tests: add tests for types
types: use the idiomatic equivalents
types: remove JSPerf references
Merge pull request #288 from dcousens/types

Types