This is an unofficial snapshot of the ISO/IEC JTC1 SC22 WG21 Core Issues List revision 116a. See http://www.open-std.org/jtc1/sc22/wg21/ for the official list.

2024-12-19


1229. Overload resolution with empty braced-init-list argument

Section: 12.2.2.8  [over.match.list]     Status: C++11     Submitter: Johannes Schaub     Date: 2010-12-09

[Voted into the WP at the March, 2011 meeting as part of paper N3262.]

The changes for issue 990 did not address the description of overload resolution when an argument is an empty braced-init-list. For example:

    struct A {
      A();
      A(std::initializer_list<int>);
      A(std::initializer_list<double>);
    };

    A a{};       // OK

    void f(A);

    void g() {
      f({});     // ambiguous
    }