Switch to unsigned ints

Signed integers have implementation-defined shifting behavior
(arithmetic vs logical)
Rename abs -> mathabs to avoid name conflict with builtin
Implement leastBitPos and test