名稱空間
變體
操作

std::experimental::nonesuch

來自 cppreference.com
< cpp‎ | 實驗性
定義於標頭檔案 <experimental/type_traits>
struct nonesuch {

    ~nonesuch() = delete;
    nonesuch(nonesuch const&) = delete;
    void operator=(nonesuch const&) = delete;

};
(庫基礎 TS v2)

std::experimental::nonesuch 是一個類型別,用於 std::experimental::detected_t 以指示檢測失敗。

nonesuch 沒有預設建構函式或初始化列表建構函式,也不是聚合體。

[編輯] 注意

nonesuch 不能構造、銷燬或複製。

[編輯] 缺陷報告

下列更改行為的缺陷報告追溯地應用於以前出版的 C++ 標準。

缺陷報告 應用於 釋出時的行為 正確的行為
LWG 2960 LFTSv2 nonesuch 可能是一個聚合體,並且具有從 {} 的隱式轉換序列。 修改為非聚合體並移除了隱式轉換序列(ICS)。