Namespaces
Variants

std::codecvt<InternT,ExternT,StateT>:: ~codecvt

From cppreference.net
헤더에 정의됨 <locale>
protected : ~codecvt ( ) ;

std:: codecvt 패싯을 소멸합니다. 이 소멸자는 보호되어 있으며 가상입니다( 기본 클래스 소멸자가 가상이기 때문). std:: codecvt 타입의 객체는 대부분의 패싯과 마찬가지로, 이 패싯을 구현하는 마지막 std::locale 객체가 범위를 벗어나거나, 사용자 정의 클래스가 std:: codecvt 에서 파생되어 공개 소멸자를 구현한 경우에만 소멸될 수 있습니다.

예제

#include <iostream>
#include <locale>
struct Destructible_codecvt : public std::codecvt<wchar_t, char, std::mbstate_t>
{
    Destructible_codecvt(std::size_t refs = 0) : codecvt(refs) {}
    // note: the implicit destructor is public
};
int main()
{
    Destructible_codecvt dc;
    // std::codecvt<wchar_t> c; // compile error: protected destructor
}