Check if object is of a given type - elegant way (C++/CLI)

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

In C# I can write:
if(someObj is someType)
{ .. }

In C++/CLI I used:
if(someObj->GetType()->Eqals(someType::typeid))
{ .. }

Is there some other way to do this stuff in C++/CLI? Perhaps something more
elegant, like C# "is" keyword?
 
Back
Top