https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109277
Bug ID: 109277
Summary: [13 Regression] type_traits:1417:30: error: invalid
use of incomplete type ‘class v8::internal::WasmArray’
Product: gcc
Version: 13.0
Status: UNCONFIRMED
Keywords: rejects-valid
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: marxin at gcc dot gnu.org
CC: redi at gcc dot gnu.org
Target Milestone: ---
Reduced from chromium, gcc-12 accepts the code:
GCC 13 pre-processed source code:
https://gist.githubusercontent.com/marxin/377cbc8221f7c36e87aebe48a55b52ba/raw/b80443940faf20f6f5db124fb6a56d9bee994fee/promise13.ii
$ g++ -std=gnu++20 promise13.ii -c -w
In file included from /usr/include/math.h:398,
from /usr/include/c++/13/cmath:47,
from ../v8/src/utils/utils.h:12,
from ../v8/src/zone/zone.h:15,
from ../v8/src/handles/handles.h:14,
from ../v8/src/ast/ast-value-factory.h:36,
from ../v8/src/ast/ast.h:10,
from
gen/v8/torque-generated/src/builtins/promise-all-element-closure-tq-csa.cc:1:
/usr/include/bits/mathcalls-helper-functions.h: In static member function
‘static int __iseqsig_type<_Float128>::__call(_Float128, _Float128)’:
/usr/include/bits/mathcalls-helper-functions.h:41:36: note: initializing
argument 1 of ‘int __iseqsigl(long double, long double)’
41 | __MATHDECL_ALIAS (int, __iseqsig,, (_Mdouble_ __x, _Mdouble_ __y),
iseqsig);
| ~~~~~~~~~~~~^~~
/usr/include/bits/mathcalls-helper-functions.h:41:53: note: initializing
argument 2 of ‘int __iseqsigl(long double, long double)’
41 | __MATHDECL_ALIAS (int, __iseqsig,, (_Mdouble_ __x, _Mdouble_ __y),
iseqsig);
| ~~~~~~~~~~~~^~~
In file included from /usr/include/c++/13/bits/move.h:57,
from /usr/include/c++/13/bits/new_allocator.h:36,
from
/usr/include/c++/13/aarch64-suse-linux/bits/c++allocator.h:33,
from /usr/include/c++/13/bits/allocator.h:46,
from /usr/include/c++/13/memory:65,
from ../v8/src/ast/ast.h:8:
/usr/include/c++/13/type_traits: In instantiation of ‘struct
std::is_convertible<v8::internal::WasmArray, v8::internal::Object>’:
../v8/src/codegen/tnode.h:273:72: required from ‘const bool
v8::internal::is_subtype<v8::internal::WasmArray,
v8::internal::WasmArray>::value’
../v8/src/codegen/tnode.h:361:75: required by substitution of ‘template<class
U, typename std::enable_if<v8::internal::is_subtype<U,
v8::internal::WasmArray>::value, int>::type <anonymous> >
v8::internal::TNode<v8::internal::WasmArray>::TNode(const
v8::internal::TNode<T>&) [with U = v8::internal::WasmArray; typename
std::enable_if<v8::internal::is_subtype<U, v8::internal::WasmArray>::value,
int>::type <anonymous> = <missing>]’
/usr/include/c++/13/tuple:188:12: required from ‘struct std::_Head_base<0,
v8::internal::TNode<v8::internal::WasmArray>, false>’
/usr/include/c++/13/tuple:259:12: required from ‘struct std::_Tuple_impl<0,
v8::internal::TNode<v8::internal::WasmArray>,
v8::internal::TNode<v8::internal::IntPtrT>,
v8::internal::TNode<v8::internal::IntPtrT> >’
/usr/include/c++/13/tuple:746:11: required from ‘class
std::tuple<v8::internal::TNode<v8::internal::WasmArray>,
v8::internal::TNode<v8::internal::IntPtrT>,
v8::internal::TNode<v8::internal::IntPtrT> >’
gen/v8/torque-generated/csa-types.h:487:80: required from here
/usr/include/c++/13/type_traits:1417:30: error: invalid use of incomplete type
‘class v8::internal::WasmArray’
1417 | : public __bool_constant<__is_convertible(_From, _To)>
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from ../v8/src/heap/factory-base.h:15,
from ../v8/src/heap/factory.h:18,
from ../v8/src/ast/ast.h:18:
gen/v8/torque-generated/class-forward-declarations.h:291:7: note: forward
declaration of ‘class v8::internal::WasmArray’
In file included from ../v8/src/codegen/interface-descriptors.h:13,
from ../v8/src/codegen/callable.h:8,
from ../v8/src/codegen/code-factory.h:8,
from ../v8/src/codegen/code-stub-assembler.h:12,
from ../v8/src/builtins/builtins-array-gen.h:8,
from
gen/v8/torque-generated/src/builtins/promise-all-element-closure-tq-csa.cc:2:
../v8/src/codegen/tnode.h: In instantiation of ‘const bool
v8::internal::is_subtype<v8::internal::WasmArray,
v8::internal::WasmArray>::value’:
../v8/src/codegen/tnode.h:361:75: required by substitution of ‘template<class
U, typename std::enable_if<v8::internal::is_subtype<U,
v8::internal::WasmArray>::value, int>::type <anonymous> >
v8::internal::TNode<v8::internal::WasmArray>::TNode(const
v8::internal::TNode<T>&) [with U = v8::internal::WasmArray; typename
std::enable_if<v8::internal::is_subtype<U, v8::internal::WasmArray>::value,
int>::type <anonymous> = <missing>]’
/usr/include/c++/13/tuple:188:12: required from ‘struct std::_Head_base<0,
v8::internal::TNode<v8::internal::WasmArray>, false>’
/usr/include/c++/13/tuple:259:12: required from ‘struct std::_Tuple_impl<0,
v8::internal::TNode<v8::internal::WasmArray>,
v8::internal::TNode<v8::internal::IntPtrT>,
v8::internal::TNode<v8::internal::IntPtrT> >’
/usr/include/c++/13/tuple:746:11: required from ‘class
std::tuple<v8::internal::TNode<v8::internal::WasmArray>,
v8::internal::TNode<v8::internal::IntPtrT>,
v8::internal::TNode<v8::internal::IntPtrT> >’
gen/v8/torque-generated/csa-types.h:487:80: required from here
../v8/src/codegen/tnode.h:273:72: error: ‘value’ is not a member of
‘std::is_convertible<v8::internal::WasmArray, v8::internal::Object>’
GCC 12 pre-processed source code:
https://gist.githubusercontent.com/marxin/cca0440a46638a1afc508c908f28e19b/raw/9d2ee4e7e466e55b961f693a769483cf85ba4126/promise12.ii
$ g++-12 -std=gnu++20 promise12.ii -c -w