Checked mode

Ran example and tests in checked mode, which revealed some type mismatch.

Also removed a few tests that tested for these type mismatches.
Merge pull request #40 from magnetfruit/issue10

Checked mode