[LLVMdev] isa and friends as an alternative to dynamic cast?

Tanya Lattner tonic at nondot.org
Thu Apr 21 19:20:22 PDT 2005


> I see a bunch of definitions scattered throughout LLVM, and I could not
> find good documentation on them. I don't understand why they exist when
> LLVM is being compiled with RTTI enabled. It seems to me that:
>
> isa<T>(x) is a substitute for (dynamic_cast<T>(x) != NULL)

Misha seems to have answered your question, but documentation is found 
here:
http://llvm.cs.uiuc.edu/docs/ProgrammersManual.html#isa

-Tanya




More information about the llvm-dev mailing list