clang API Documentation
#include <ExprCXX.h>


Public Member Functions | |
| CXXTypeidExpr (QualType Ty, TypeSourceInfo *Operand, SourceRange R) | |
| CXXTypeidExpr (QualType Ty, Expr *Operand, SourceRange R) | |
| CXXTypeidExpr (EmptyShell Empty, bool isExpr) | |
| bool | isPotentiallyEvaluated () const |
| bool | isTypeOperand () const |
| QualType | getTypeOperand (ASTContext &Context) const |
| Retrieves the type operand of this typeid() expression after various required adjustments (removing reference types, cv-qualifiers). | |
| TypeSourceInfo * | getTypeOperandSourceInfo () const |
| Retrieve source information for the type operand. | |
| void | setTypeOperandSourceInfo (TypeSourceInfo *TSI) |
| Expr * | getExprOperand () const |
| void | setExprOperand (Expr *E) |
| SourceLocation | getLocStart () const LLVM_READONLY |
| SourceLocation | getLocEnd () const LLVM_READONLY |
| SourceRange | getSourceRange () const LLVM_READONLY |
| void | setSourceRange (SourceRange R) |
| child_range | children () |
Static Public Member Functions | |
| static bool | classof (const Stmt *T) |
A C++ typeid expression (C++ [expr.typeid]), which gets the type_info that corresponds to the supplied type, or the (possibly dynamic) type of the supplied expression.
This represents code like typeid(int) or typeid(*objPtr)
| clang::CXXTypeidExpr::CXXTypeidExpr | ( | QualType | Ty, |
| TypeSourceInfo * | Operand, | ||
| SourceRange | R | ||
| ) | [inline] |
| clang::CXXTypeidExpr::CXXTypeidExpr | ( | QualType | Ty, |
| Expr * | Operand, | ||
| SourceRange | R | ||
| ) | [inline] |
| clang::CXXTypeidExpr::CXXTypeidExpr | ( | EmptyShell | Empty, |
| bool | isExpr | ||
| ) | [inline] |
| child_range clang::CXXTypeidExpr::children | ( | ) | [inline] |
Reimplemented from clang::Stmt.
Definition at line 602 of file ExprCXX.h.
References isTypeOperand().
| static bool clang::CXXTypeidExpr::classof | ( | const Stmt * | T | ) | [inline, static] |
Reimplemented from clang::Expr.
Definition at line 597 of file ExprCXX.h.
References clang::Stmt::getStmtClass().
| Expr* clang::CXXTypeidExpr::getExprOperand | ( | ) | const [inline] |
Definition at line 582 of file ExprCXX.h.
References isTypeOperand().
Referenced by clang::canTypeidThrow(), clang::CodeGen::CodeGenFunction::EmitCXXTypeidExpr(), isPotentiallyEvaluated(), and clang::EvaluatedExprVisitor< ImplClass >::VisitCXXTypeidExpr().
| SourceLocation clang::CXXTypeidExpr::getLocEnd | ( | ) | const [inline] |
Reimplemented from clang::Stmt.
Definition at line 593 of file ExprCXX.h.
References clang::SourceRange::getEnd().
| SourceLocation clang::CXXTypeidExpr::getLocStart | ( | ) | const [inline] |
Reimplemented from clang::Stmt.
Definition at line 592 of file ExprCXX.h.
References clang::SourceRange::getBegin().
| SourceRange clang::CXXTypeidExpr::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.
| QualType CXXTypeidExpr::getTypeOperand | ( | ASTContext & | Context | ) | const |
Retrieves the type operand of this typeid() expression after various required adjustments (removing reference types, cv-qualifiers).
Definition at line 43 of file ExprCXX.cpp.
References clang::QualType::getNonReferenceType(), clang::TypeSourceInfo::getType(), clang::ASTContext::getUnqualifiedArrayType(), and isTypeOperand().
Referenced by clang::CodeGen::CodeGenFunction::EmitCXXTypeidExpr().
| TypeSourceInfo* clang::CXXTypeidExpr::getTypeOperandSourceInfo | ( | ) | const [inline] |
Retrieve source information for the type operand.
Definition at line 572 of file ExprCXX.h.
References isTypeOperand().
| bool CXXTypeidExpr::isPotentiallyEvaluated | ( | ) | const |
Determine whether this typeid has a type operand which is potentially evaluated, per C++11 [expr.typeid]p3.
Definition at line 28 of file ExprCXX.cpp.
References clang::Type::getAsCXXRecordDecl(), getExprOperand(), clang::Expr::getType(), clang::Expr::isGLValue(), and isTypeOperand().
Referenced by clang::CodeGen::CodeGenFunction::EmitCXXTypeidExpr(), and clang::EvaluatedExprVisitor< ImplClass >::VisitCXXTypeidExpr().
| bool clang::CXXTypeidExpr::isTypeOperand | ( | ) | const [inline] |
Definition at line 565 of file ExprCXX.h.
Referenced by clang::canTypeidThrow(), children(), clang::CodeGen::CodeGenFunction::EmitCXXTypeidExpr(), getExprOperand(), getTypeOperand(), getTypeOperandSourceInfo(), isPotentiallyEvaluated(), setExprOperand(), and setTypeOperandSourceInfo().
| void clang::CXXTypeidExpr::setExprOperand | ( | Expr * | E | ) | [inline] |
Definition at line 587 of file ExprCXX.h.
References isTypeOperand().
| void clang::CXXTypeidExpr::setSourceRange | ( | SourceRange | R | ) | [inline] |
| void clang::CXXTypeidExpr::setTypeOperandSourceInfo | ( | TypeSourceInfo * | TSI | ) | [inline] |
Definition at line 577 of file ExprCXX.h.
References isTypeOperand().