随笔分类 - C++
C++ 之explicit 用法
摘要:explicitC++ Specific This keyword is a declaration specifier that can only be applied to in-class constructor declarations. Constructors declared explicit will not be considered for implicit conversions. For example:class X {public: explicit X(int); //legal explicit X(double) { //legal // ... }};exp
阅读全文
浙公网安备 33010602011771号