clang API Documentation

Public Member Functions | Static Public Member Functions
clang::ParenExpr Class Reference

#include <Expr.h>

Inheritance diagram for clang::ParenExpr:
Inheritance graph
[legend]
Collaboration diagram for clang::ParenExpr:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 ParenExpr (SourceLocation l, SourceLocation r, Expr *val)
 ParenExpr (EmptyShell Empty)
 Construct an empty parenthesized expression.
const ExprgetSubExpr () const
ExprgetSubExpr ()
void setSubExpr (Expr *E)
SourceRange getSourceRange () const LLVM_READONLY
SourceLocation getLParen () const
 Get the location of the left parentheses '('.
void setLParen (SourceLocation Loc)
SourceLocation getRParen () const
 Get the location of the right parentheses ')'.
void setRParen (SourceLocation Loc)
child_range children ()

Static Public Member Functions

static bool classof (const Stmt *T)
static bool classof (const ParenExpr *)

Detailed Description

ParenExpr - This represents a parethesized expression, e.g. "(1)". This AST node is only formed if full location information is requested.

Definition at line 1476 of file Expr.h.


Constructor & Destructor Documentation

clang::ParenExpr::ParenExpr ( SourceLocation  l,
SourceLocation  r,
Expr val 
) [inline]

Definition at line 1480 of file Expr.h.

clang::ParenExpr::ParenExpr ( EmptyShell  Empty) [inline, explicit]

Construct an empty parenthesized expression.

Definition at line 1489 of file Expr.h.


Member Function Documentation

child_range clang::ParenExpr::children ( ) [inline]

Reimplemented from clang::Stmt.

Definition at line 1512 of file Expr.h.

static bool clang::ParenExpr::classof ( const Stmt T) [inline, static]

Reimplemented from clang::Expr.

Definition at line 1506 of file Expr.h.

References clang::Stmt::getStmtClass().

static bool clang::ParenExpr::classof ( const ParenExpr ) [inline, static]

Definition at line 1509 of file Expr.h.

SourceLocation clang::ParenExpr::getLParen ( ) const [inline]

Get the location of the left parentheses '('.

Definition at line 1499 of file Expr.h.

Referenced by clang::ASTNodeImporter::VisitParenExpr().

SourceLocation clang::ParenExpr::getRParen ( ) const [inline]

Get the location of the right parentheses ')'.

Definition at line 1503 of file Expr.h.

Referenced by clang::ASTNodeImporter::VisitParenExpr().

SourceRange clang::ParenExpr::getSourceRange ( ) const [inline]

SourceLocation tokens are not useful in isolation - they are low level value objects created/interpreted by SourceManager. We assume AST clients will have a pointer to the respective SourceManager.

Reimplemented from clang::Stmt.

Definition at line 1496 of file Expr.h.

Referenced by clang::Sema::DiagnoseEqualityWithExtraParens().

const Expr* clang::ParenExpr::getSubExpr ( ) const [inline]

Definition at line 1492 of file Expr.h.

Referenced by clang::Sema::ActOnCastExpr(), and clang::ASTNodeImporter::VisitParenExpr().

Expr* clang::ParenExpr::getSubExpr ( ) [inline]

Definition at line 1493 of file Expr.h.

void clang::ParenExpr::setLParen ( SourceLocation  Loc) [inline]

Definition at line 1500 of file Expr.h.

void clang::ParenExpr::setRParen ( SourceLocation  Loc) [inline]

Definition at line 1504 of file Expr.h.

void clang::ParenExpr::setSubExpr ( Expr E) [inline]

Definition at line 1494 of file Expr.h.


The documentation for this class was generated from the following file: