// RUN: %clang_cc1 %s -std=c++20 -fsyntax-only -fcxx-exceptions -verify
// verify no value-dependent-assertion crash in constexpr function body and no
// bogus diagnostics.
;
constexpr void
;
constexpr int
constexpr int
constexpr int
constexpr int
constexpr int
constexpr bool
constexpr void
constexpr int
constexpr int
constexpr int // expected-error {{use of undeclared identifier 'undef'}}
static_assert; // expected-error {{static assertion expression is not an integral constant expression}}
array = ; // expected-error {{use of undeclared identifier 'undef'}}
constexpr void
constexpr int // expected-error {{cannot initialize return object of type 'int'}}
constexpr int force12 = ; // expected-error {{must be initialized by a constant}}
// Check that a variety of broken loops don't crash constant evaluation.
// We're not checking specific recovery here so don't assert diagnostics.
; // expected-error + {{}}
; // expected-error + {{}}
; // expected-error + {{}}
// FIXME: should bail out instead of looping.
// expected-note@-2 + {{infinite loop}}
// expected-note@-3 {{in call}}
; // expected-error + {{}}
; // expected-error + {{}}
; // expected-error + {{}}
; // expected-error + {{}}
;// expected-error + {{}}
; // expected-error + {{}}
; // expected-error + {{}}
; // expected-error + {{}}