The Frink programming language
ncreep.github.io
ncreep.github.io
And yes, it's a big ad hoc bag of hopefully-useful values. It turns out that a big ad hoc bag of hopefully-useful values is, in fact, sometimes useful.
(Of course there's more to Frink than its big bag of handy predefined values. But I take it it's only the big bag of handy predefined values you're criticizing, and indeed that is one of the more interesting features of Frink.)
I was bored the other day and put up some old C++ code. [1] Some years ago I was playing around with C++ templates (pre C++11) to see how far I can go and I came up with exactly that kind of unit checking and conversion. The trickiest part was eliminating common terms when dividing units but once you figure out how to approach it, it's not that hard. Complete unit inference is definitely possible and maybe even worthwhile depending on your use case.
That said, it is still just some experimentation, but maybe someone feels inspired :)
[1] https://github.com/jpommerening/template-hell.git (Note: don't expect proper documentation yet, I'm still figuring out how to structure namespaces there, etc.)
Edit: I remember the over-the-top template substitutions made XCode 3 crash back in the day. You have been warned.
(And I think it's from a dozen years ago, W|A was still a dream at the time :) )