__is_base_of

From Appmethod Topics
Jump to: navigation, search

Go Up to Type Trait Functions (C++0x) Index


Category

Type Trait Functions

Syntax

bool __is_base_of (typename Base, typename Derived)

Returns true if and only if Base is a base class of Derived.

Error if Derived is an incomplete type and Base is a class-type..

Note: False (but well formed) if either Base or Derived is a union or non-class type, even if the other is an incomplete type.

True if any class in the DAG of base classes for Derived is Base. This includes private, protected, ambiguous or virtual bases so simply return true the first time the search finds a match.

See Also