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++/54604] New: ICE (segv) calling explicitly member function template specialization in a lambda


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

             Bug #: 54604
           Summary: ICE (segv) calling explicitly member function template
                    specialization in a lambda
    Classification: Unclassified
           Product: gcc
           Version: 4.7.1
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: delong.j@fb.com


Small repro case:

% cat crash.cpp
class C {
public:
  template<bool Fun> void f() { }
  template<bool Fun> void g() {
    auto foo = [&]() { f<Fun>(); };
  }
};

int main() {
   C c;
   c.g<false>();
}

% g++_4.7 -std=gnu++0x crash.cpp
crash.cpp: In instantiation of âC::g() [with bool Fun = false]::<lambda()>â:
crash.cpp:5:18:   required from âstruct C::g() [with bool Fun =
false]::<lambda()>â
crash.cpp:5:34:   required from âvoid C::g() [with bool Fun = false]â
crash.cpp:11:15:   required from here
crash.cpp:5:24: internal compiler error: Segmentation fault
Please submit a full bug report,
with preprocessed source if appropriate.
See <http://gcc.gnu.org/bugs.html> for instructions.


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