cppreference.com
建立新帳號
登入
名字空間
頁面
討論
變換
不转换
简体
繁體
大陆简体
香港繁體
澳門繁體
大马简体
新加坡简体
台灣正體
檢視
檢視
編輯
歷史
動作
标准库标头
<cassert>
出自cppreference.com
<
cpp
|
header
C++
編譯器支持
自立實現與有宿主實現
語言
標準庫
標準庫標頭
具名要求
功能特性測試宏
(C++20)
語言支持庫
概念庫
(C++20)
診斷庫
內存管理庫
元編程庫
(C++11)
通用工具庫
容器庫
迭代器庫
範圍庫
(C++20)
演算法庫
字元串庫
文本處理庫
數值庫
日期和時間庫
輸入/輸出庫
文件系統庫
(C++17)
並發支持庫
(C++11)
執行控制庫
(C++26)
技術規範
符號索引
外部庫
[編輯]
標準庫頭
語言支持
<cfloat>
<climits>
<compare>
(C++20)
<contracts>
(C++26)
<coroutine>
(C++20)
<csetjmp>
<csignal>
<cstdarg>
<cstddef>
<cstdint>
(C++11)
<cstdlib>
<exception>
<initializer_list>
(C++11)
<limits>
<new>
<source_location>
(C++20)
<stdfloat>
(C++23)
<typeinfo>
<version>
(C++20)
概念
<concepts>
(C++20)
診斷
<cassert>
<cerrno>
<debugging>
(C++26)
<stacktrace>
(C++23)
<stdexcept>
<system_error>
(C++11)
內存管理
<memory>
<memory_resource>
(C++17)
<scoped_allocator>
(C++11)
元編程
<type_traits>
(C++11)
<ratio>
(C++11)
通用工具
<any>
(C++17)
<bitset>
<bit>
(C++20)
<charconv>
(C++17)
<expected>
(C++23)
<format>
(C++20)
<functional>
<optional>
(C++17)
<stdbit.h>
(C++26)
<tuple>
(C++11)
<typeindex>
(C++11)
<utility>
<variant>
(C++17)
容器
<array>
(C++11)
<deque>
<flat_map>
(C++23)
<flat_set>
(C++23)
<forward_list>
(C++11)
<hive>
(C++26)
<inplace_vector>
(C++26)
<list>
<map>
<mdspan>
(C++23)
<queue>
<set>
<span>
(C++20)
<stack>
<unordered_map>
(C++11)
<unordered_set>
(C++11)
<vector>
迭代器
<iterator>
範圍
<generator>
(C++23)
<ranges>
(C++20)
演算法
<algorithm>
<numeric>
字元串
<cctype>
<cstring>
<cuchar>
(C++11)
<cwchar>
<cwctype>
<string_view>
(C++17)
<string>
文本處理
<clocale>
<codecvt>
(
C++11/17/26*
)
<locale>
<regex>
(C++11)
<text_encoding>
(C++26)
cpp/header#數值庫數值
<cfenv>
(C++11)
<cmath>
<complex>
<linalg>
(C++26)
<numbers>
(C++20)
<random>
(C++11)
<simd>
(C++26)
<stdckdint.h>
(C++26)
<valarray>
時間
<chrono>
(C++11)
<ctime>
C 兼容性
<ccomplex>
(
C++11/17/20*
)
<ciso646>
(C++20 前)
<cstdalign>
(
C++11/17/20*
)
<cstdbool>
(
C++11/17/20*
)
<ctgmath>
(
C++11/17/20*
)
輸入/輸出
<cinttypes>
(C++11)
<cstdio>
<filesystem>
(C++17)
<fstream>
<iomanip>
<iosfwd>
<iostream>
<ios>
<istream>
<ostream>
<print>
(C++23)
<spanstream>
(C++23)
<sstream>
<streambuf>
<strstream>
(
C++98/26*
)
<syncstream>
(C++20)
並發支持
<atomic>
(C++11)
<barrier>
(C++20)
<condition_variable>
(C++11)
<future>
(C++11)
<hazard_pointer>
(C++26)
<latch>
(C++20)
<mutex>
(C++11)
<rcu>
(C++26)
<semaphore>
(C++20)
<shared_mutex>
(C++14)
<stdatomic.h>
(C++23)
<stop_token>
(C++20)
<thread>
(C++11)
執行支持
<execution>
(C++17)
[編輯]
此標頭原作為
<assert.h>
存在於 C 標準庫。
此頭文件是
錯誤處理
庫的一部分。
宏
assert
若用戶指定的條件非
true
則中斷程序。可以在發行構建中禁用。
(宏函數)
[編輯]
[
編輯
]
概要
#define assert(E) /* 见描述 */