As some operator functions take a fixed (or at least limited) number
of arguments, an ellipsis is not allowed as argument for such operator
functions.
However, none of the following four cases is diagnosed since GCC 3.0:

===================================
struct A
{
    A& operator= (int, ...);
    A& operator[] (int, ...);
    A& operator++ (...);
    operator int(...);
};
===================================

All cases were diagnosed correctly in GCC 2.95.3 (although the compiler
would crash later). Therefore I'm rating this as a regression.


-- 
           Summary: [3.4/4.0/4.1/4.2 regression] Invalid ellipsis in
                    operator not diagnosed
           Product: gcc
           Version: 4.2.0
            Status: UNCONFIRMED
          Keywords: accepts-invalid, monitored
          Severity: normal
          Priority: P3
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: reichelt at gcc dot gnu dot org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26291

Reply via email to