This page is a snapshot from the LWG issues list, see the Library Active Issues List for more information and the meaning of CD1 status.

### 275. Wrong type in num_get::get() overloads

Section: 28.4.3.2.2 [facet.num.get.members] Status: CD1 Submitter: Matt Austern Opened: 2000-11-02 Last modified: 2016-01-28

Priority: Not Prioritized

View all other issues in [facet.num.get.members].

View all issues with CD1 status.

Discussion:

In 22.2.2.1.1, we have a list of overloads for num_get<>::get(). There are eight overloads, all of which are identical except for the last parameter. The overloads are:

- long&
- unsigned short&
- unsigned int&
- unsigned long&
- short&
- double&
- long double&
- void*&

There is a similar list, in 22.2.2.1.2, of overloads for num_get<>::do_get(). In this list, the last parameter has the types:

- long&
- unsigned short&
- unsigned int&
- unsigned long&
- float&
- double&
- long double&
- void*&

These two lists are not identical. They should be, since `get` is supposed to call `do_get` with exactly the arguments it was given.

Proposed resolution:

In 28.4.3.2.2 [facet.num.get.members], change

      iter_type get(iter_type in, iter_type end, ios_base& str,
                    ios_base::iostate& err, short& val) const;

to

      iter_type get(iter_type in, iter_type end, ios_base& str,
                    ios_base::iostate& err, float& val) const;