http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58825
Bug ID: 58825 Summary: endless loop compiling nested bind expression Product: gcc Version: 4.8.2 Status: UNCONFIRMED Severity: normal Priority: P3 Component: libstdc++ Assignee: unassigned at gcc dot gnu.org Reporter: joerg.rich...@pdv-fs.de g++ -std=c++11 -x c++ -c - <<EOF #include <functional> using namespace std; struct Win { void setMini( bool ); bool isMini(); }; bool neg( bool val ); void foo( Win* w ) { function<void()> a = bind( &Win::setMini, w, bind( neg, bind( &Win::isMini, w ) ) ); } EOF #################### Works with GCC 4.7.3 IMHO there are two bugs. One in libstdc++ that valid code is rejected. The other one that the error reporting does not stop.