名稱空間
變體
操作

thrd_success, thrd_timedout, thrd_busy, thrd_nomem, thrd_error

來自 cppreference.com
< c‎ | thread
在標頭檔案 <threads.h> 中定義
enum {

    thrd_success = /* unspecified */,
    thrd_nomem = /* unspecified */,
    thrd_timedout = /* unspecified */,
    thrd_busy = /* unspecified */,
    thrd_error = /* unspecified */

};
(C11 起)

執行緒狀態和錯誤的識別符號。

常量 解釋
thrd_success 指示成功返回值
thrd_nomem 指示因記憶體不足導致的非成功返回值
thrd_timedout 指示超時返回值
thrd_busy 指示因資源暫時不可用導致的非成功返回值
thrd_error 指示非成功返回值

[編輯] 參考資料

  • C17 標準 (ISO/IEC 9899:2018)
  • 7.26.1/5 thrd_success, thrd_timedout, ... (p: 275)
  • C11 標準 (ISO/IEC 9899:2011)
  • 7.26.1/5 thrd_success, thrd_timedout, ... (p: 377)