Movatterモバイル変換


[0]ホーム

URL:


cppreference.com
Namespaces
Variants
    Actions

      Standard library header <typeinfo>

      From cppreference.com
      <cpp‎ |header
       
       
      Standard library headers
       

      This header is part of thetype support library.

      Contents

      [edit]Classes

      contains some type’s information, the class returned by the typeid operator
      (class)[edit]
      exception that is thrown if an argument in atypeid expression is null
      (class)[edit]
      exception that is thrown by an invaliddynamic_cast expression, i.e. a cast of reference type fails
      (class)[edit]

      [edit]Synopsis

      // all freestandingnamespace std{class type_info;class bad_cast;class bad_typeid;}

      [edit]Classstd::type_info

      namespace std{class type_info{public:virtual ~type_info();constexprbool operator==(const type_info& rhs)constnoexcept;bool before(const type_info& rhs)constnoexcept;    size_t hash_code()constnoexcept;constchar* name()constnoexcept;     type_info(const type_info&)= delete;    type_info& operator=(const type_info&)= delete;};}

      [edit]Classstd::bad_cast

      namespace std{class bad_cast:public exception{public:// see description for the specification of the special member functionsconstexprconstchar* what()constnoexcept override;};}

      [edit]Classstd::bad_typeid

      namespace std{class bad_typeid:public exception{public:// see description for the specification of the special member functionsconstexprconstchar* what()constnoexcept override;};}
      Retrieved from "https://en.cppreference.com/mwiki/index.php?title=cpp/header/typeinfo&oldid=164010"

      [8]ページ先頭

      ©2009-2025 Movatter.jp