How to workaround the inconsistent definition of numeric_limits::min()?

前端 未结 7 1364
予麋鹿
予麋鹿 2021-02-08 00:05

The numeric_limits traits is supposed to be a general way of obtaining various type infomation, to be able to do things like

template
T min(con         


        
相关标签:
7条回答
  • 2021-02-08 00:43

    You can use Boost libraries. The library Numeric Conversions provides a class called bounds that can be used consistently.

    See the documentation here.

    0 讨论(0)
提交回复
热议问题