https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117889

            Bug ID: 117889
           Summary: [15 regression] Failure to build qtwebengine-6.8.1
           Product: gcc
           Version: 15.0
            Status: UNCONFIRMED
          Keywords: rejects-valid
          Severity: normal
          Priority: P3
         Component: libstdc++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: sjames at gcc dot gnu.org
  Target Milestone: ---

Building qtwebengine-6.8.1 with GCC 15 gives:
```
[...]
/usr/lib/gcc/aarch64-unknown-linux-gnu/15/include/g++-v15/type_traits: In
substitution of ‘template<class _Up>  requires !(is_same_v<std::optional<_Tp>,
typename std::remove_cvref<_It2>::type>) && (is_constructible_v<_Tp, const
_Up&>) && (__construct_from_contained_value<_Up, typename std::remove_cv<
<template-parameter-1-1> >::type>) constexpr
std::optional<blink::LayoutUnit>::optional(const std::optional<_Tp>&) [with _Up
= blink::LayoutUnit]’:
/usr/lib/gcc/aarch64-unknown-linux-gnu/15/include/g++-v15/type_traits:1143:25: 
 required by substitution of ‘template<class _Tp, class ... _Args> using
std::__is_constructible_impl = std::__bool_constant<__is_constructible(_Tp,
_Args ...)> [with _Tp = blink::LayoutUnit; _Args =
{std::optional<blink::LayoutUnit>&}]’
 1143 |       = __bool_constant<__is_constructible(_Tp, _Args...)>;
      |                         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/lib/gcc/aarch64-unknown-linux-gnu/15/include/g++-v15/type_traits:1148:12: 
 required from ‘struct std::is_constructible<blink::LayoutUnit,
std::optional<blink::LayoutUnit>&>’
 1148 |     struct is_constructible
      |            ^~~~~~~~~~~~~~~~
/usr/lib/gcc/aarch64-unknown-linux-gnu/15/include/g++-v15/type_traits:181:35:  
required by substitution of ‘template<class ... _Bn>
std::__detail::__first_t<std::integral_constant<bool, false>, typename
std::enable_if<(!(bool)(_Bn::value)), void>::type ...>
std::__detail::__or_fn(int) [with _Bn =
{std::is_constructible<blink::LayoutUnit, std::optional<blink::LayoutUnit>&>,
std::is_convertible<std::optional<blink::LayoutUnit>&, blink::LayoutUnit>,
std::is_constructible<blink::LayoutUnit, std::optional<blink::LayoutUnit> >,
std::is_convertible<std::optional<blink::LayoutUnit>, blink::LayoutUnit>,
std::is_constructible<blink::LayoutUnit, const
std::optional<blink::LayoutUnit>&>, std::is_convertible<const
std::optional<blink::LayoutUnit>&, blink::LayoutUnit>,
std::is_constructible<blink::LayoutUnit, const std::optional<blink::LayoutUnit>
>, std::is_convertible<const std::optional<blink::LayoutUnit>,
blink::LayoutUnit>}]’
  181 |                                     
__enable_if_t<!bool(_Bn::value)>...>;
      |                                                               ^~~~~
/usr/lib/gcc/aarch64-unknown-linux-gnu/15/include/g++-v15/type_traits:199:41:  
required from ‘struct std::__or_<std::is_constructible<blink::LayoutUnit,
std::optional<blink::LayoutUnit>&>,
std::is_convertible<std::optional<blink::LayoutUnit>&, blink::LayoutUnit>,
std::is_constructible<blink::LayoutUnit, std::optional<blink::LayoutUnit> >,
std::is_convertible<std::optional<blink::LayoutUnit>, blink::LayoutUnit>,
std::is_constructible<blink::LayoutUnit, const
std::optional<blink::LayoutUnit>&>, std::is_convertible<const
std::optional<blink::LayoutUnit>&, blink::LayoutUnit>,
std::is_constructible<blink::LayoutUnit, const std::optional<blink::LayoutUnit>
>, std::is_convertible<const std::optional<blink::LayoutUnit>,
blink::LayoutUnit> >’
  199 |     : decltype(__detail::__or_fn<_Bn...>(0))
      |                ~~~~~~~~~~~~~~~~~~~~~~~~~^~~
/usr/lib/gcc/aarch64-unknown-linux-gnu/15/include/g++-v15/optional:823:45:  
required from ‘constexpr const bool
std::optional<blink::LayoutUnit>::__construct_from_contained_value<blink::LayoutUnit,
blink::LayoutUnit>’
  823 |           = !__converts_from_optional<_Tp, _From>::value;
      |                                                    ^~~~~
/usr/lib/gcc/aarch64-unknown-linux-gnu/15/include/g++-v15/optional:881:7:  
required by substitution of ‘template<class _Up>  requires
!(is_same_v<std::optional<_Tp>, typename std::remove_cvref<_It2>::type>) &&
(is_constructible_v<_Tp, const _Up&>) && (__construct_from_contained_value<_Up,
typename std::remove_cv< <template-parameter-1-1> >::type>) constexpr
std::optional<blink::LayoutUnit>::optional(const std::optional<_Tp>&) [with _Up
= blink::LayoutUnit]’
  881 |           && __construct_from_contained_value<_Up>
      |              ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../../../../../qtwebengine-everywhere-src-6.8.1/src/3rdparty/chromium/third_party/blink/renderer/core/layout/table/table_constraint_space_data.h:49:11:
  required from here
   49 |           baseline(baseline),
      |           ^~~~~~~~~~~~~~~~~~
/usr/lib/gcc/aarch64-unknown-linux-gnu/15/include/g++-v15/optional:883:2:  
required by the constraints of ‘template<class _Tp> template<class _Up> 
requires !(is_same_v<std::optional<_Tp>, typename
std::remove_cvref<_It2>::type>) && (is_constructible_v<_Tp, const _Up&>) &&
(__construct_from_contained_value<_Up, typename std::remove_cv<
<template-parameter-1-1> >::type>) constexpr std::optional<_Tp>::optional(const
std::optional<_From>&)’
/usr/lib/gcc/aarch64-unknown-linux-gnu/15/include/g++-v15/optional:881:14:
error: satisfaction of atomic constraint ‘__construct_from_contained_value<_Up,
typename std::remove_cv< <template-parameter-1-1> >::type> [with _Tp = _Tp; _Up
= _Up]’ depends on itself
  881 |           && __construct_from_contained_value<_Up>
      |              ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
[...]
```

Building with 14 works, as does using 14-preprocessed sources with 15. I'll
attach both.

Reply via email to