The only real correct way that I can see to implement Units such as SI Units and Imperial Units in a computer language is to employ dependant types. This would allow seamless integration into the type system without requiring anything more than library support for unit systems.