Bug ID: 81781
           Summary: consexpr pointer comparsion error
           Product: gcc
           Version: 7.1.1
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot
          Reporter: bobk-off at yandex dot ru
  Target Milestone: ---

Any gcc version cannot compile code below with error: '((&
std::integral_constant<int, 5>::value) == (& std::integral_constant<int,
10>::value))' is not a constant expression. Compilation success only if
template arguments of left side and right side parts of equation are equal.

static constexpr bool x = &std::integral_constant<int, 5>::value ==
&std::integral_constant<int, 10>::value;

Reply via email to