/external/clang/lib/StaticAnalyzer/Core/ |
D | SVals.cpp | 247 castAs<NonLoc>().dumpToStream(os); in dumpToStream() 250 castAs<Loc>().dumpToStream(os); in dumpToStream() 261 const nonloc::ConcreteInt& C = castAs<nonloc::ConcreteInt>(); in dumpToStream() 271 os << castAs<nonloc::SymbolVal>().getSymbol(); in dumpToStream() 275 const nonloc::LocAsInteger& C = castAs<nonloc::LocAsInteger>(); in dumpToStream() 280 const nonloc::CompoundVal& C = castAs<nonloc::CompoundVal>(); in dumpToStream() 296 const nonloc::LazyCompoundVal &C = castAs<nonloc::LazyCompoundVal>(); in dumpToStream() 311 os << castAs<loc::ConcreteInt>().getValue().getZExtValue() << " (Loc)"; in dumpToStream() 314 os << "&&" << castAs<loc::GotoLabel>().getLabel()->getName(); in dumpToStream() 317 os << '&' << castAs<loc::MemRegionVal>().getRegion()->getString(); in dumpToStream()
|
D | SimpleSValBuilder.cpp | 64 return Val.getAs<Loc>() ? evalCastFromLoc(Val.castAs<Loc>(), CastTy) in dispatchCast() 65 : evalCastFromNonLoc(Val.castAs<NonLoc>(), CastTy); in dispatchCast() 106 bool b = val.castAs<nonloc::ConcreteInt>().getValue().getBoolValue(); in evalCastFromNonLoc() 115 llvm::APSInt i = val.castAs<nonloc::ConcreteInt>().getValue(); in evalCastFromNonLoc() 146 llvm::APSInt i = val.castAs<loc::ConcreteInt>().getValue(); in evalCastFromLoc() 164 return val.castAs<nonloc::ConcreteInt>().evalMinus(*this); in evalMinus() 173 return X.castAs<nonloc::ConcreteInt>().evalComplement(*this); in evalComplement() 313 Loc lhsL = lhs.castAs<nonloc::LocAsInteger>().getLoc(); in evalBinOpNN() 317 rhs.castAs<nonloc::LocAsInteger>().getLoc(), in evalBinOpNN() 321 llvm::APSInt i = rhs.castAs<nonloc::ConcreteInt>().getValue(); in evalBinOpNN() [all …]
|
D | SimpleConstraintManager.cpp | 73 return assume(state, Cond.castAs<Loc>(), Assumption); in assume() 93 const MemRegion *R = Cond.castAs<loc::MemRegionVal>().getRegion(); in assumeAux() 111 bool b = Cond.castAs<loc::ConcreteInt>().getValue() != 0; in assumeAux() 162 nonloc::SymbolVal SV = Cond.castAs<nonloc::SymbolVal>(); in assumeAux() 213 bool b = Cond.castAs<nonloc::ConcreteInt>().getValue() != 0; in assumeAux() 219 return assumeAux(state, Cond.castAs<nonloc::LocAsInteger>().getLoc(), in assumeAux()
|
D | SValBuilder.cpp | 87 return evalCastFromNonLoc(val.castAs<NonLoc>(), ArrayIndexTy); in convertToArrayIndex() 344 return evalBinOpLN(state, op, *LV, rhs.castAs<NonLoc>(), type); in evalBinOp() 353 return evalBinOpLN(state, op, *RV, lhs.castAs<NonLoc>(), type); in evalBinOp() 356 return evalBinOpNN(state, op, lhs.castAs<NonLoc>(), rhs.castAs<NonLoc>(), in evalBinOp() 364 .castAs<DefinedOrUnknownSVal>(); in evalEQ() 427 return evalCastFromLoc(val.castAs<Loc>(), castTy); in evalCast() 453 val = StateMgr.ArrayToPointer(val.castAs<Loc>(), elemTy); in evalCast() 468 return evalCastFromLoc(val.castAs<Loc>(), castTy); in evalCast()
|
D | Store.cpp | 403 Loc BaseL = Base.castAs<Loc>(); in getLValueFieldOrIvar() 408 BaseR = BaseL.castAs<loc::MemRegionVal>().getRegion(); in getLValueFieldOrIvar() 448 const MemRegion* BaseRegion = Base.castAs<loc::MemRegionVal>().getRegion(); in getLValueElement() 454 Offset = svalBuilder.convertToArrayIndex(Offset).castAs<NonLoc>(); in getLValueElement() 476 BaseIdx.castAs<nonloc::ConcreteInt>().getValue(); in getLValueElement() 490 const llvm::APSInt& OffI = Offset.castAs<nonloc::ConcreteInt>().getValue(); in getLValueElement()
|
D | ExprEngine.cpp | 284 ProcessStmt(const_cast<Stmt*>(E.castAs<CFGStmt>().getStmt()), Pred); in processCFGElement() 287 ProcessInitializer(E.castAs<CFGInitializer>().getInitializer(), Pred); in processCFGElement() 293 ProcessImplicitDtor(E.castAs<CFGImplicitDtor>(), Pred); in processCFGElement() 527 ProcessAutomaticObjDtor(D.castAs<CFGAutomaticObjDtor>(), Pred, Dst); in ProcessImplicitDtor() 530 ProcessBaseDtor(D.castAs<CFGBaseDtor>(), Pred, Dst); in ProcessImplicitDtor() 533 ProcessMemberDtor(D.castAs<CFGMemberDtor>(), Pred, Dst); in ProcessImplicitDtor() 536 ProcessTemporaryDtor(D.castAs<CFGTemporaryDtor>(), Pred, Dst); in ProcessImplicitDtor() 554 const MemRegion *Region = dest.castAs<loc::MemRegionVal>().getRegion(); in ProcessAutomaticObjDtor() 581 VisitCXXDestructor(BaseTy, BaseVal.castAs<loc::MemRegionVal>().getRegion(), in ProcessBaseDtor() 595 State->getLValue(Member, State->getSVal(ThisVal).castAs<Loc>()); in ProcessMemberDtor() [all …]
|
D | ExprEngineC.cpp | 522 BlockEdge BE = N->getLocation().castAs<BlockEdge>(); in VisitLogicalExpr() 544 CFGStmt Elem = SrcBlock->rbegin()->castAs<CFGStmt>(); in VisitLogicalExpr() 551 DefinedOrUnknownSVal DefinedRHS = RHSVal.castAs<DefinedOrUnknownSVal>(); in VisitLogicalExpr() 644 SrcBlock = PP.castAs<BlockEdge>().getSrc(); in VisitGuardedExpr() 825 state = state->BindExpr(U, LCtx, evalComplement(V.castAs<NonLoc>())); in VisitUnaryOperator() 829 state = state->BindExpr(U, LCtx, evalMinus(V.castAs<NonLoc>())); in VisitUnaryOperator() 846 Result = evalBinOp(state, BO_EQ, V.castAs<NonLoc>(), X, in VisitUnaryOperator() 888 DefinedSVal V2 = V2_untested.castAs<DefinedSVal>(); in VisitIncrementDecrementOperator()
|
D | ProgramState.cpp | 127 const MemRegion *R = loc.castAs<loc::MemRegionVal>().getRegion(); in bindDefault() 348 Idx.castAs<NonLoc>(), Min, indexTy); in assumeInBound() 354 svalBuilder.evalBinOpNN(this, BO_Add, UpperBound.castAs<NonLoc>(), in assumeInBound() 361 SVal inBound = svalBuilder.evalBinOpNN(this, BO_LT, newIdx.castAs<NonLoc>(), in assumeInBound() 362 newBound.castAs<NonLoc>(), Ctx.IntTy); in assumeInBound() 368 return CM.assume(this, inBound.castAs<DefinedSVal>(), Assumption); in assumeInBound()
|
/external/clang/lib/StaticAnalyzer/Checkers/ |
D | VLASizeChecker.cpp | 113 DefinedSVal sizeD = sizeV.castAs<DefinedSVal>(); in checkPreStmt() 134 svalBuilder.evalCast(sizeD, SizeTy, SE->getType()).castAs<NonLoc>(); in checkPreStmt() 142 state, BO_Mul, ArrayLength, EleSizeVal.castAs<NonLoc>(), SizeTy); in checkPreStmt() 148 DefinedOrUnknownSVal ArraySize = ArraySizeVal.castAs<DefinedOrUnknownSVal>(); in checkPreStmt()
|
D | ArrayBoundCheckerV2.cpp | 56 NonLoc getByteOffset() const { return byteOffset.castAs<NonLoc>(); } in getByteOffset() 147 extentVal.castAs<NonLoc>(), in checkLocation() 259 return svalBuilder.evalBinOpNN(state, BO_Add, x.castAs<NonLoc>(), in addValue() 260 y.castAs<NonLoc>(), in addValue() 298 index.castAs<NonLoc>(), in computeOffset()
|
D | CStringChecker.cpp | 283 DefinedOrUnknownSVal Size = Extent.castAs<DefinedOrUnknownSVal>(); in CheckLocation() 286 DefinedOrUnknownSVal Idx = ER->getIndex().castAs<DefinedOrUnknownSVal>(); in CheckLocation() 369 NonLoc One = svalBuilder.makeIntVal(1, sizeTy).castAs<NonLoc>(); in CheckBufferAccess() 371 .evalBinOpNN(state, BO_Sub, *Length, One, sizeTy).castAs<NonLoc>(); in CheckBufferAccess() 579 state->assume(willOverflow.castAs<DefinedOrUnknownSVal>()); in checkAdditionOverflow() 932 loc::MemRegionVal destRegVal = destVal.castAs<loc::MemRegionVal>(); in evalCopyCommon() 1054 state->getSVal(Left, LCtx).castAs<DefinedOrUnknownSVal>(); in evalMemcmp() 1056 state->getSVal(Right, LCtx).castAs<DefinedOrUnknownSVal>(); in evalMemcmp() 1176 .castAs<DefinedOrUnknownSVal>()); in evalstrLengthCommon() 1193 NonLoc resultNL = result.castAs<NonLoc>(); in evalstrLengthCommon() [all …]
|
D | UnixAPIChecker.cpp | 110 NonLoc oflags = V.castAs<NonLoc>(); in CheckOpen() 112 .makeIntVal(Val_O_CREAT.getValue(), oflagsEx->getType()).castAs<NonLoc>(); in CheckOpen() 118 DefinedSVal maskedFlags = maskedFlagsUC.castAs<DefinedSVal>(); in CheckOpen() 203 state->assume(argVal.castAs<DefinedSVal>()); in IsZeroByteAllocation()
|
D | ObjCSelfInitChecker.cpp | 258 unsigned selfFlags = getSelfFlags(state->getSVal(argV.castAs<Loc>()), C); in checkPreCall() 289 addSelfFlag(state, state->getSVal(argV.castAs<Loc>()), prevFlags, C); in checkPostCall() 315 addSelfFlag(state, state->getSVal(location.castAs<Loc>()), SelfFlag_Self, in checkLocation() 424 loc::MemRegionVal MRV = location.castAs<loc::MemRegionVal>(); in isSelfVar()
|
D | ObjCContainersChecker.cpp | 76 State->set<ArraySizeMap>(ArraySym, SizeV.castAs<DefinedSVal>())); in REGISTER_MAP_WITH_PROGRAMSTATE() 129 DefinedSVal Idx = IdxVal.castAs<DefinedSVal>(); in checkPreStmt()
|
D | ReturnPointerRangeChecker.cpp | 49 DefinedOrUnknownSVal Idx = ER->getIndex().castAs<DefinedOrUnknownSVal>(); in checkPreStmt()
|
D | ArrayBoundChecker.cpp | 47 DefinedOrUnknownSVal Idx = ER->getIndex().castAs<DefinedOrUnknownSVal>(); in checkLocation()
|
D | ObjCAtSyncChecker.cpp | 63 llvm::tie(notNullState, nullState) = state->assume(V.castAs<DefinedSVal>()); in checkPreStmt()
|
D | NSErrorChecker.cpp | 228 setFlag<NSErrorOut>(state, state->getSVal(loc.castAs<Loc>()), C); in checkLocation() 233 setFlag<CFErrorOut>(state, state->getSVal(loc.castAs<Loc>()), C); in checkLocation()
|
/external/clang/lib/Sema/ |
D | TypeLocBuilder.h | 74 return pushImpl(T, LocalSize, LocalAlign).castAs<TypeSpecTypeLoc>(); in pushTypeSpec() 97 TyLocType Loc = TypeLoc(T, 0).castAs<TyLocType>(); in push() 100 return pushImpl(T, LocalSize, LocalAlign).castAs<TyLocType>(); in push()
|
/external/clang/lib/AST/ |
D | CXXInheritance.cpp | 272 = cast<CXXRecordDecl>(BaseSpec->getType()->castAs<RecordType>() in lookupInBases() 379 return Specifier->getType()->castAs<RecordType>()->getDecl() in FindBaseClass() 389 Specifier->getType()->castAs<RecordType>()->getDecl() in FindVirtualBaseClass() 397 Specifier->getType()->castAs<RecordType>()->getDecl(); in FindTagMember() 414 Specifier->getType()->castAs<RecordType>()->getDecl(); in FindOrdinaryMember() 433 Specifier->getType()->castAs<RecordType>()->getDecl(); in FindNestedNameSpecifierMember() 711 cast<CXXRecordDecl>(I->getType()->castAs<RecordType>()->getDecl()); in AddIndirectPrimaryBases() 734 cast<CXXRecordDecl>(I->getType()->castAs<RecordType>()->getDecl()); in getIndirectPrimaryBases()
|
D | MangleNumberingContext.cpp | 30 return ++ManglingNumbers[Key->castAs<FunctionProtoType>()]; in getManglingNumber()
|
D | TypeLoc.cpp | 117 CLASS##TypeLoc TLCasted = TL.castAs<CLASS##TypeLoc>(); \ in initializeImpl() 137 if (Cur.castAs<FunctionProtoTypeLoc>().getTypePtr() in getBeginLoc() 183 if (Cur.castAs<FunctionProtoTypeLoc>().getTypePtr()->hasTrailingReturn()) in getEndLoc()
|
/external/clang/include/clang/AST/ |
D | TypeLocVisitor.h | 24 Visit##CLASSNAME(TyLoc.castAs<CLASSNAME>())
|
/external/clang/lib/CodeGen/ |
D | CGExprComplex.cpp | 200 QualType Elem = E->getType()->castAs<ComplexType>()->getElementType(); in VisitCXXScalarValueInitExpr() 206 QualType Elem = E->getType()->castAs<ComplexType>()->getElementType(); in VisitImplicitValueInitExpr() 388 SrcType = SrcType->castAs<ComplexType>()->getElementType(); in EmitComplexToComplexCast() 389 DestType = DestType->castAs<ComplexType>()->getElementType(); in EmitComplexToComplexCast() 403 DestType = DestType->castAs<ComplexType>()->getElementType(); in EmitScalarToComplexCast() 607 if (Op.Ty->castAs<ComplexType>()->getElementType()->isUnsignedIntegerType()) { in EmitBinDiv() 802 QualType Ty = E->getType()->castAs<ComplexType>()->getElementType(); in VisitInitListExpr() 815 CGF.ConvertType(E->getType()->castAs<ComplexType>()->getElementType()); in VisitVAArgExpr()
|
/external/clang/unittests/AST/ |
D | SourceLocationTest.cpp | 162 Node.getUnqualifiedLoc().castAs<TemplateSpecializationTypeLoc>(); in getRange() 187 Node.getUnqualifiedLoc().castAs<UnaryTransformTypeLoc>(); in getRange()
|