nholthaus / units

a compile-time, header-only, dimensional analysis and unit conversion library built on c++14 with no dependencies.
http://nholthaus.github.io/units/
MIT License
934 stars 134 forks source link

Some numeric_limits and numeric helper functions were missing #331

Open siposcsaba89 opened 3 months ago

siposcsaba89 commented 3 months ago

Extended std::numeric_limits class with some functions needed to use it with yaml-cpp.

siposcsaba89 commented 1 month ago

I was hoping for this! I have to jump through hoops to get inf.

A few comments. Also, you should probably add tests in https://github.com/nholthaus/units/blob/master/unitTests/main.cpp

Also added some unit tests for limits. Can you check them? Maybe you have some other tests in mind.