https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83102
Bug ID: 83102
Summary: go bootstrap error in ast-dump.cc due to
__is_invocable failure
Product: gcc
Version: 8.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: bootstrap
Assignee: unassigned at gcc dot gnu.org
Reporter: msebor at gcc dot gnu.org
Target Milestone: ---
Bootstrapping GCC 8.0 (at r255038) on x86_64 fails with the error while
compiling gcc/go/gofrontend/ast-dump.cc:
In file included from
/opt/notnfs/msebor/build/gcc-svn/prev-x86_64-pc-linux-gnu/libstdc++-v3/include/map:60,
from /opt/notnfs/msebor/src/gcc/svn/gcc/go/go-system.h:36,
from
/opt/notnfs/msebor/src/gcc/svn/gcc/go/gofrontend/ast-dump.cc:7:
/opt/notnfs/msebor/build/gcc-svn/prev-x86_64-pc-linux-gnu/libstdc++-v3/include/bits/stl_tree.h:
In instantiation of ‘class std::_Rb_tree<Import_init*, Import_init*,
std::_Identity<Import_init*>, Import_init_lt, std::allocator<Import_init*> >’:
/opt/notnfs/msebor/build/gcc-svn/prev-x86_64-pc-linux-gnu/libstdc++-v3/include/bits/stl_set.h:133:17:
required from ‘class std::set<Import_init*, Import_init_lt>’
/opt/notnfs/msebor/src/gcc/svn/gcc/go/gofrontend/gogo.h:127:37: required from
here
/opt/notnfs/msebor/build/gcc-svn/prev-x86_64-pc-linux-gnu/libstdc++-v3/include/bits/stl_tree.h:452:7:
error: static assertion failed: comparison object must be invocable with two
arguments of key type
static_assert(__is_invocable<const _Compare&, const _Key&, const
_Key&>{},
^~~~~~~~~~~~~
/opt/notnfs/msebor/src/gcc/svn/gcc/go/Make-lang.in:239: recipe for target
'go/ast-dump.o' failed
A test case for the error suggests the problem is either in libstdc++ or the
C++ front end:
$ cat t.C && g++ -S -Wall ... t.C
#include <set>
struct Import_init { int init_name () const; };
struct Import_init_lt {
bool operator()(const Import_init* i1, const Import_init* i2)
{
return i1->init_name() < i2->init_name();
}
};
class Import_init_set : public std::set<Import_init*, Import_init_lt> { };
In file included from
/opt/notnfs/msebor/build/gcc-svn/prev-x86_64-pc-linux-gnu/libstdc++-v3/include/set:60,
from t.C:1:
/opt/notnfs/msebor/build/gcc-svn/prev-x86_64-pc-linux-gnu/libstdc++-v3/include/bits/stl_tree.h:
In instantiation of ‘class std::_Rb_tree<Import_init*, Import_init*,
std::_Identity<Import_init*>, Import_init_lt, std::allocator<Import_init*> >’:
/opt/notnfs/msebor/build/gcc-svn/prev-x86_64-pc-linux-gnu/libstdc++-v3/include/bits/stl_set.h:133:17:
required from ‘class std::set<Import_init*, Import_init_lt>’
t.C:13:37: required from here
/opt/notnfs/msebor/build/gcc-svn/prev-x86_64-pc-linux-gnu/libstdc++-v3/include/bits/stl_tree.h:452:7:
error: static assertion failed: comparison object must be invocable with two
arguments of key type
static_assert(__is_invocable<const _Compare&, const _Key&, const
_Key&>{},
^~~~~~~~~~~~~