Class TryCatch

Inheritance Relationships

Base Type

Class Documentation

class TryCatch : public seq::Stmt

Public Functions

TryCatch()
Block *getBlock()
Var *getVar(unsigned idx)
Block *addCatch(types::Type *type)
Block *getFinally()
BasicBlock *getExceptionBlock()
void codegenReturn(Expr *expr, llvm::BasicBlock *&block)
void codegenBreak(llvm::BasicBlock *&block)
void codegenContinue(llvm::BasicBlock *&block)
void resolveTypes()

Performs type resolution on this statement and all sub-expressions/statements/etc. This is called prior to Expr::getType().

void codegen0(llvm::BasicBlock *&block)

Performs code generation for this statement.

Parameters
  • block: reference to block where code should be generated; possibly modified to point to a new block where codegen should resume

TryCatch *clone(Generic *ref)

Clones this statement. ref is used internally to keep track of cloned objects, and to make sure we don’t clone certain objects twice.

Return

cloned statement

Parameters
  • ref: generic object that is being cloned

Public Static Functions

StructType *getPadType(llvm::LLVMContext &context)
StructType *getExcType(llvm::LLVMContext &context)
GlobalVariable *getTypeIdxVar(llvm::Module *module, types::Type *catchType)