Topic: numeric_limits or traits?


Author: 74221.306@compuserve.com (Jean-Louis Leroy)
Date: 1996/04/25
Raw View
Hi,

`numeric_limits<>' looks pretty much like a `traits' class to me.
Anybody knows why it was not called `numeric_traits<>'? Especially
that some of its members have little to do with `limits' per se
(is_integer, radix...).

jl :)
---
[ comp.std.c++ is moderated.  To submit articles: try just posting with      ]
[ your news-reader.  If that fails, use mailto:std-c++@ncar.ucar.edu         ]
[ FAQ:      http://reality.sgi.com/employees/austern_mti/std-c++/faq.html    ]
[ Policy:   http://reality.sgi.com/employees/austern_mti/std-c++/policy.html ]
[ Comments? mailto:std-c++-request@ncar.ucar.edu                             ]





Author: Nathan Myers <ncm@cantrip.org>
Date: 1996/04/26
Raw View
Jean-Louis Leroy wrote:

> `numeric_limits<>' looks pretty much like a `traits' class to me.
> Anybody knows why it was not called `numeric_traits<>'? Especially
> that some of its members have little to do with `limits' per se
> (is_integer, radix...).

As usual, the answer is that nobody cared enough about the idea
to propose changing it at this late date.  <limits> is the name
of the header it appears in, BTW, and it has that name for
historical C library reasons.

Nathan Myers
ncm@cantrip.org  http://www.cantrip.org/
---
[ comp.std.c++ is moderated.  To submit articles: Try just posting with your
                newsreader.  If that fails, use mailto:std-c++@ncar.ucar.edu
  comp.std.c++ FAQ: http://reality.sgi.com/austern/std-c++/faq.html
  Moderation policy: http://reality.sgi.com/austern/std-c++/policy.html
  Comments? mailto:std-c++-request@ncar.ucar.edu
]