std::money_put<CharT,OutputIt>::~money_put
From cppreference.com
| ヘッダー <locale> で定義 |
||
| protected: ~money_put(); |
||
std::money_putファセットを破棄します。このデストラクタはprotectedであり、仮想(基底クラスのデストラクタが仮想であるため)です。std::money_put型のオブジェクトは、ほとんどのファセットと同様に、このファセットを実装している最後のstd::localeオブジェクトがスコープを外れるか、またはユーザー定義クラスがstd::money_putから派生し、publicなデストラクタを実装している場合にのみ破棄できます。
[編集] 例
このコードを実行
#include <iostream> #include <locale> struct Destructible_money_put : public std::money_put<wchar_t> { Destructible_money_put(std::size_t refs = 0) : money_put(refs) {} // note: the implicit destructor is public }; int main() { Destructible_money_put dc; // std::money_put<wchar_t> c; // compile error: protected destructor }