Enable compiler warnings, fix warnings so generated, and fix ostream behavior with const unitval

Fixes #18