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++/15759] New: "internal compiler error: Segmentation fault" on small isolated code.


int defValue() { return(0); }
int(*defaultValue)() = defValue;

void a(int blah = defaultValue()) {}

int main() { a(); }


/*
$ g++ a.cpp -o a
a.cpp: In function `int main()':
a.cpp:20: internal compiler error: Segmentation fault

If I drop the indirection, like this:

void a(int blah = defValue()) {}

..it compiles.
*/

-- 
           Summary: "internal compiler error: Segmentation fault" on small
                    isolated code.
           Product: gcc
           Version: 3.4.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: larsnostdal at organizer dot net
                CC: gcc-bugs at gcc dot gnu dot org


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


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