[LLVMdev] Question about recursive types

Gordon Henriksen gordonhenriksen at me.com
Fri Oct 3 12:20:29 PDT 2008


On 2008-10-03, at 13:42, Haohui Mai wrote:
> // NewSTy is potentially invalidated, but StructTy (a PATypeHolder) is
> // kept up-to-date
> NewSTy = cast<StructType>(StructTy.get());
>
> However, it does not work. The compiler says that the API of  
> PointerType::get

Use PointerType::getUnqual.
> (PATypeHolder &) does not exist.

Make sure to resolve the type handle by invoking its 'get' method.

— Gordon



More information about the llvm-dev mailing list