[LLVMdev] SwitchInst::addCase with BlockAddress

Duncan Sands baldrick at free.fr
Mon Aug 1 04:16:05 PDT 2011


Hi,

> What I'm missing is, therefore, how do I get a ConstantInt out of a Constant
> obtained via ConstantExpr::getPointerCast?

you can't.  A ConstantInt is not the same thing as a Constant with integer type.
A ConstantInt is a constant which is just a number, such as 3.

Ciao, Duncan.



More information about the llvm-dev mailing list