class CXXThrowExpr

Declaration

class CXXThrowExpr : public Expr { /* full declaration omitted */ };

Description

A C++ throw-expression (C++ [except.throw]). This handles 'throw' (for re-throwing the current exception) and 'throw' assignment-expression. When assignment-expression isn't present, Op will be null.

Declared at: clang/include/clang/AST/ExprCXX.h:1181

Inherits from: Expr

Member Variables

private clang::Stmt* Operand
The optional expression in the throw statement.

Inherited from Stmt:

protected

Method Overview

Inherited from Expr:

Inherited from ValueStmt:

Inherited from Stmt:

Methods

CXXThrowExpr(clang::Expr* Operand,
             clang::QualType Ty,
             clang::SourceLocation Loc,
             bool IsThrownVariableInScope)

Declared at: clang/include/clang/AST/ExprCXX.h:1192

Parameters

clang::Expr* Operand
clang::QualType Ty
clang::SourceLocation Loc
bool IsThrownVariableInScope

CXXThrowExpr(clang::Stmt::EmptyShell Empty)

Declared at: clang/include/clang/AST/ExprCXX.h:1199

Parameters

clang::Stmt::EmptyShell Empty

clang::Stmt::child_range children()

Declared at: clang/include/clang/AST/ExprCXX.h:1227

clang::Stmt::const_child_range children() const

Declared at: clang/include/clang/AST/ExprCXX.h:1231

static bool classof(const clang::Stmt* T)

Declared at: clang/include/clang/AST/ExprCXX.h:1222

Parameters

const clang::Stmt* T

clang::SourceLocation getBeginLoc() const

Declared at: clang/include/clang/AST/ExprCXX.h:1215

clang::SourceLocation getEndLoc() const

Declared at: clang/include/clang/AST/ExprCXX.h:1216

const clang::Expr* getSubExpr() const

Declared at: clang/include/clang/AST/ExprCXX.h:1201

clang::Expr* getSubExpr()

Declared at: clang/include/clang/AST/ExprCXX.h:1202

clang::SourceLocation getThrowLoc() const

Declared at: clang/include/clang/AST/ExprCXX.h:1204

bool isThrownVariableInScope() const

Description

Determines whether the variable thrown by this expression (if any!) is within the innermost try block. This information is required to determine whether the NRVO can apply to this variable.

Declared at: clang/include/clang/AST/ExprCXX.h:1211