clang API Documentation
#include <Expr.h>


Public Types | |
| typedef clang::CastKind | CastKind |
| typedef CXXBaseSpecifier ** | path_iterator |
| typedef const CXXBaseSpecifier *const * | path_const_iterator |
Public Member Functions | |
| CastKind | getCastKind () const |
| void | setCastKind (CastKind K) |
| const char * | getCastKindName () const |
| Expr * | getSubExpr () |
| const Expr * | getSubExpr () const |
| void | setSubExpr (Expr *E) |
| Expr * | getSubExprAsWritten () |
| Retrieve the cast subexpression as it was written in the source code, looking through any implicit casts or other intermediate nodes introduced by semantic analysis. | |
| const Expr * | getSubExprAsWritten () const |
| bool | path_empty () const |
| unsigned | path_size () const |
| path_iterator | path_begin () |
| path_iterator | path_end () |
| path_const_iterator | path_begin () const |
| path_const_iterator | path_end () const |
| void | setCastPath (const CXXCastPath &Path) |
| child_range | children () |
Static Public Member Functions | |
| static bool | classof (const Stmt *T) |
| static bool | classof (const CastExpr *) |
Protected Member Functions | |
| CastExpr (StmtClass SC, QualType ty, ExprValueKind VK, const CastKind kind, Expr *op, unsigned BasePathSize) | |
| CastExpr (StmtClass SC, EmptyShell Empty, unsigned BasePathSize) | |
| Construct an empty cast. | |
CastExpr - Base class for type casts, including both implicit casts (ImplicitCastExpr) and explicit casts that have some representation in the source code (ExplicitCastExpr's derived classes).
| typedef const CXXBaseSpecifier* const* clang::CastExpr::path_const_iterator |
| clang::CastExpr::CastExpr | ( | StmtClass | SC, |
| QualType | ty, | ||
| ExprValueKind | VK, | ||
| const CastKind | kind, | ||
| Expr * | op, | ||
| unsigned | BasePathSize | ||
| ) | [inline, protected] |
Definition at line 2498 of file Expr.h.
References clang::Stmt::CastExprBits, and CK_Invalid.
| clang::CastExpr::CastExpr | ( | StmtClass | SC, |
| EmptyShell | Empty, | ||
| unsigned | BasePathSize | ||
| ) | [inline, protected] |
| child_range clang::CastExpr::children | ( | ) | [inline] |
Reimplemented from clang::Stmt.
| static bool clang::CastExpr::classof | ( | const Stmt * | T | ) | [inline, static] |
Reimplemented from clang::Expr.
Reimplemented in clang::CStyleCastExpr, clang::ExplicitCastExpr, clang::ImplicitCastExpr, clang::ObjCBridgedCastExpr, clang::CXXFunctionalCastExpr, clang::CXXConstCastExpr, clang::CXXReinterpretCastExpr, clang::CXXDynamicCastExpr, clang::CXXStaticCastExpr, and clang::CXXNamedCastExpr.
Definition at line 2554 of file Expr.h.
References clang::Stmt::getStmtClass().
| static bool clang::CastExpr::classof | ( | const CastExpr * | ) | [inline, static] |
| CastKind clang::CastExpr::getCastKind | ( | ) | const [inline] |
Definition at line 2527 of file Expr.h.
References clang::Stmt::CastExprBits.
Referenced by CanDynamicCastThrow(), clang::CodeGen::CodeGenFunction::EmitCastLValue(), getSubExprAsWritten(), clang::Expr::isConstantInitializer(), isSimpleArrayDecayOperand(), clang::Expr::isUnusedResultAWarning(), maybeRebuildARCConsumingStmt(), shouldExtendReceiverForInnerPointerMessage(), ShouldNullCheckClassCastValue(), clang::ento::ExprEngine::VisitCast(), clang::ASTNodeImporter::VisitCStyleCastExpr(), and clang::ASTNodeImporter::VisitImplicitCastExpr().
| const char * CastExpr::getCastKindName | ( | ) | const |
Definition at line 1125 of file Expr.cpp.
References clang::CK_AnyPointerToBlockPointerCast, clang::CK_ARCConsumeObject, clang::CK_ARCExtendBlockObject, clang::CK_ARCProduceObject, clang::CK_ARCReclaimReturnedObject, clang::CK_ArrayToPointerDecay, clang::CK_AtomicToNonAtomic, clang::CK_BaseToDerived, clang::CK_BaseToDerivedMemberPointer, clang::CK_BitCast, clang::CK_BlockPointerToObjCPointerCast, clang::CK_ConstructorConversion, clang::CK_CPointerToObjCPointerCast, clang::CK_Dependent, clang::CK_DerivedToBase, clang::CK_DerivedToBaseMemberPointer, clang::CK_Dynamic, clang::CK_FloatingCast, clang::CK_FloatingComplexCast, clang::CK_FloatingComplexToBoolean, clang::CK_FloatingComplexToIntegralComplex, clang::CK_FloatingComplexToReal, clang::CK_FloatingRealToComplex, clang::CK_FloatingToBoolean, clang::CK_FloatingToIntegral, clang::CK_FunctionToPointerDecay, clang::CK_IntegralCast, clang::CK_IntegralComplexCast, clang::CK_IntegralComplexToBoolean, clang::CK_IntegralComplexToFloatingComplex, clang::CK_IntegralComplexToReal, clang::CK_IntegralRealToComplex, clang::CK_IntegralToBoolean, clang::CK_IntegralToFloating, clang::CK_IntegralToPointer, clang::CK_LValueBitCast, clang::CK_LValueToRValue, clang::CK_MemberPointerToBoolean, clang::CK_NonAtomicToAtomic, clang::CK_NoOp, clang::CK_NullToMemberPointer, clang::CK_NullToPointer, clang::CK_ObjCObjectLValueCast, clang::CK_PointerToBoolean, clang::CK_PointerToIntegral, clang::CK_ToUnion, clang::CK_ToVoid, clang::CK_UncheckedDerivedToBase, clang::CK_UserDefinedConversion, and clang::CK_VectorSplat.
| Expr* clang::CastExpr::getSubExpr | ( | ) | [inline] |
Definition at line 2531 of file Expr.h.
Referenced by CanDynamicCastThrow(), clang::CodeGen::CodeGenFunction::EmitCastLValue(), clang::CodeGen::CodeGenFunction::EmitDynamicCast(), EvalVal(), clang::ObjCBridgedCastExpr::getSourceRange(), clang::ImplicitCastExpr::getSourceRange(), clang::CStyleCastExpr::getSourceRange(), getSubExprAsWritten(), GetUnreachableLoc(), clang::CXXDynamicCastExpr::isAlwaysNull(), clang::CallExpr::isBuiltinCall(), clang::Expr::isConstantInitializer(), isSimpleArrayDecayOperand(), maybeRebuildARCConsumingStmt(), shouldExtendReceiverForInnerPointerMessage(), ShouldNullCheckClassCastValue(), clang::TreeTransform< Derived >::TransformCXXNamedCastExpr(), clang::ASTNodeImporter::VisitCStyleCastExpr(), and clang::ASTNodeImporter::VisitImplicitCastExpr().
| Expr * CastExpr::getSubExprAsWritten | ( | ) |
Retrieve the cast subexpression as it was written in the source code, looking through any implicit casts or other intermediate nodes introduced by semantic analysis.
Definition at line 1232 of file Expr.cpp.
References clang::CK_ConstructorConversion, clang::CK_UserDefinedConversion, getCastKind(), and getSubExpr().
Referenced by getSubExprAsWritten(), and clang::TreeTransform< Derived >::TransformCXXNamedCastExpr().
| const Expr* clang::CastExpr::getSubExprAsWritten | ( | ) | const [inline] |
Definition at line 2539 of file Expr.h.
References getSubExprAsWritten().
| path_iterator clang::CastExpr::path_begin | ( | ) | [inline] |
Definition at line 2547 of file Expr.h.
Referenced by DumpBasePath(), and clang::CodeGen::CodeGenFunction::EmitCastLValue().
| path_const_iterator clang::CastExpr::path_begin | ( | ) | const [inline] |
| bool clang::CastExpr::path_empty | ( | ) | const [inline] |
Definition at line 2545 of file Expr.h.
References clang::Stmt::CastExprBits.
Referenced by DumpBasePath(), and ImportCastPath().
| path_iterator clang::CastExpr::path_end | ( | ) | [inline] |
Definition at line 2548 of file Expr.h.
References path_size().
Referenced by DumpBasePath(), and clang::CodeGen::CodeGenFunction::EmitCastLValue().
| path_const_iterator clang::CastExpr::path_end | ( | ) | const [inline] |
Definition at line 2550 of file Expr.h.
References path_size().
| unsigned clang::CastExpr::path_size | ( | ) | const [inline] |
Definition at line 2546 of file Expr.h.
References clang::Stmt::CastExprBits.
Referenced by HandleBaseToDerivedCast(), and path_end().
| void clang::CastExpr::setCastKind | ( | CastKind | K | ) | [inline] |
Definition at line 2528 of file Expr.h.
References clang::Stmt::CastExprBits.
| void CastExpr::setCastPath | ( | const CXXCastPath & | Path | ) |
Definition at line 1274 of file Expr.cpp.
Referenced by clang::CXXStaticCastExpr::Create(), clang::CXXDynamicCastExpr::Create(), clang::CXXReinterpretCastExpr::Create(), clang::CXXFunctionalCastExpr::Create(), clang::ImplicitCastExpr::Create(), and clang::CStyleCastExpr::Create().