| Oracle FAQ | Your Portal to the Oracle Knowledge Grid | |
Home -> Community -> Usenet -> comp.databases.theory -> Re: Storing units in the database
Misha Dorman wrote:
> Marshall Spight wrote:
> > I believe that C++, for example, has everything you need to
> > be able to do this sort of thing in the type system.
>
> See e.g.
> http://www.awprofessional.com/articles/article.asp?p=375705&seqNum=1,
> which describes a framework for enforcing dimensional correctness;
> extension to handle automatic units declaration and conversion is not
> too hard (the hardest part is probably that a naive implementation will
> have lots of rounding error -- probably want to implement it using
> rationals rather than floating point).
Now the question to ask is do those templates, metafunctions and lambdas really simpler than, say
20 * kg * 30 * m / c^2
To quote somebody (commented my own work!-): "Computer buffs really excel at complicating simple things". Received on Tue Jul 12 2005 - 16:00:10 CDT
![]() |
![]() |