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

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Blocks|                            |55004

--- Comment #3 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Here is a reduced testcase for an invalid case:
```
struct AssertionResult {
    explicit AssertionResult(const auto &success) {}
    operator bool() const;
};
template <typename U> constexpr auto constexpr_iterator_test(U opt) -> bool {
    switch (0)
    case 0:
        if (const AssertionResult gtest_ar{1})
            return true;
    return false;
};
static_assert(constexpr_iterator_test(0));
```

I have not checked if the original code is valid or not.


Referenced Bugs:

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=55004
[Bug 55004] [meta-bug] constexpr issues

Reply via email to