1 //===----------------------------------------------------------------------===//
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
7 //===----------------------------------------------------------------------===//
9 // UNSUPPORTED: c++03, c++11, c++14, c++17, c++20
11 // Make sure we can use `std::unreachable()`. We can't actually execute it cause that would be
12 // UB, but we can make sure that it doesn't cause a linker error or something like that.
15 #include <type_traits>
18 int main(int argc
, char**) {
24 static_assert(std::is_same_v
<decltype(std::unreachable()), void>);