LLVM casting support in generated hierarchies