翻譯 https://en.cppreference.com/w/cpp/language/coroutines[https://en.cppr...
1、實(shí)現(xiàn) 2、demo code 輸出
1、實(shí)現(xiàn)分析 通過(guò)模版特例化 __is_void_helper<void> 完成 void 的特定情況處理。
1、實(shí)現(xiàn)分析 模版處理過(guò)程中會(huì)自動(dòng)完成 const volatile int 的排序 2、demo code 輸出:
1、實(shí)現(xiàn)分析 2、關(guān)于 __is_assignable 通過(guò)修改日志確定 __is_assignable 是編譯器gcc 內(nèi)部實(shí)現(xiàn)邏輯,不是通過(guò)...
1、實(shí)現(xiàn)分析 integral_constant 獲取 __is_constructible 返回結(jié)果 2、__is_constructible...
1、說(shuō)明 This template is designed to provide compile-time constants as type...
1、實(shí)現(xiàn)分析 定義一個(gè)模版類(lèi),只有一個(gè)成員type定義;通過(guò) Partial specialization 完成條件為true時(shí)的type定義,...
個(gè)人理解 右值引用就是在語(yǔ)義上為避免不必要的參數(shù)傳遞過(guò)程中執(zhí)行構(gòu)造、析構(gòu)提供支持,優(yōu)化性能。 說(shuō)明 在C++中,右值引用是一種對(duì)右值(rvalu...