This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c++/28349] New: [4.0/4.1/4.2 regression] ICE with va_arg


The following valid (though questionable) code snippet triggers an ICE
since GCC 3.1:

=========================================
#include <stdarg.h>

void foo(int, ...)
{
    va_list va;
    int i;
    i = va_arg(va, int&);
}
=========================================

bug.cc: In function 'void foo(int, ...)':
bug.cc:7: warning: cannot receive objects of non-POD type 'int&' through '...';
call will abort at runtime
bug.cc:7: internal compiler error: in build_modify_expr, at cp/typeck.c:5643
Please submit a full bug report, [etc.]


-- 
           Summary: [4.0/4.1/4.2 regression] ICE with va_arg
           Product: gcc
           Version: 4.2.0
            Status: UNCONFIRMED
          Keywords: ice-on-valid-code, 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=28349


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]