sun::codegen::CodegenState::InsertPointGuard

sun::codegen::CodegenState::InsertPointGuard

struct · Source (opens in a new tab)

struct sun::codegen::CodegenState::InsertPointGuard

Returns the builder to where it was, so emitting a nested function or a synthesized helper does not strand the outer body's insertion point.

Restores nothing if the builder had no insertion point to begin with.

Public Functions

InsertPointGuard

InsertPointGuard(const InsertPointGuard &)=delete

public · function · Source (opens in a new tab)

sun::codegen::CodegenState::InsertPointGuard::InsertPointGuard(const InsertPointGuard &)=delete

Saves the current LLVM insertion point for later restoration.

InsertPointGuard(CodegenState &s)

public · function · Source (opens in a new tab)

sun::codegen::CodegenState::InsertPointGuard::InsertPointGuard(CodegenState &s)

Saves the current LLVM insertion point for later restoration.

Related: CodegenState

operator=

public · function · Source (opens in a new tab)

InsertPointGuard & sun::codegen::CodegenState::InsertPointGuard::operator=(const InsertPointGuard &)=delete

Disallows assignment so ownership and object identity cannot be duplicated.

Related: InsertPointGuard

~InsertPointGuard

public · function · Source (opens in a new tab)

sun::codegen::CodegenState::InsertPointGuard::~InsertPointGuard()

Restores the previous LLVM instruction insertion point.

Public Fields

block

public · variable · Source (opens in a new tab)

llvm::BasicBlock* sun::codegen::CodegenState::InsertPointGuard::block

No documentation comment.

point

public · variable · Source (opens in a new tab)

llvm::BasicBlock::iterator sun::codegen::CodegenState::InsertPointGuard::point

No documentation comment.

state

public · variable · Source (opens in a new tab)

CodegenState& sun::codegen::CodegenState::InsertPointGuard::state

No documentation comment.

Related: CodegenState