Boost logo

Boost :

Subject: Re: [boost] Boost.Math and Math Constants
From: Christopher Kormanyos (e_float_at_[hidden])
Date: 2011-12-08 13:56:38


>> How about simply >> _1 >> _10 >> _100 >> ... >> then?  *if* it's deemed desirable to have such constants in the first >> place.  I.e., in what instances are the corresponding literals insufficient? > We decided not to add constants that were simple integers, > if there's a good use case we could certainly add them though. -------------------------------------------------------------- I guess (1) would be better than one(). The only real use for them that I know is with non-built-in types that lack conversion to/from int. (This arises with explicit ctors, etc.) But since boost policy wants user-defined types to be convertible, the int (1) is better than the subroutine one(), etc. I guess this was a relic in my brain. Sorry. Best regards, Chris.


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk