https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95093

            Bug ID: 95093
           Summary: Implement DR 1966, Colon following enumeration
                    elaborated-type-specifier
           Product: gcc
           Version: unknown
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: mpolacek at gcc dot gnu.org
  Target Milestone: ---

In C++11

  enum E { };
  void f(bool b)
  {
    E e = b ? *new enum E : E{};
  }

should now compile: the colon is not an enum-base, it's part of a ternary
operator.  But we think we're defining a new type here, and reject it.

See http://wg21.link/cwg1966

Reply via email to