[LoongArch] Supports FP_TO_SINT operation for fp16 (#118303)
[llvm-project.git] / libcxx / test / std / language.support / support.exception / exception.terminate / terminate / terminate.pass.cpp
blobf585c77d84b9cb1466bb1c5d7174b4fb359a367f
1 //===----------------------------------------------------------------------===//
2 //
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
6 //
7 //===----------------------------------------------------------------------===//
9 // test terminate
11 #include <exception>
12 #include <cstdlib>
13 #include <cassert>
15 #include "test_macros.h"
17 void f1()
19 std::exit(0);
22 int main(int, char**)
24 std::set_terminate(f1);
25 std::terminate();
26 assert(false);
28 return 0;