Skip to content

Commit 34eb3ca

Browse files
committed
[analyzer] Avoid small vectors of non-default-constructibles.
Unconfuses certain compilers. llvm-svn: 372942 (cherry picked from commit 4ed9793)
1 parent 40f5913 commit 34eb3ca

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

clang/include/clang/StaticAnalyzer/Core/PathSensitive/CallEvent.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -347,7 +347,7 @@ class CallEvent {
347347
ProgramStateRef invalidateRegions(unsigned BlockCount,
348348
ProgramStateRef Orig = nullptr) const;
349349

350-
using FrameBindingTy = std::pair<Loc, SVal>;
350+
using FrameBindingTy = std::pair<SVal, SVal>;
351351
using BindingsTy = SmallVectorImpl<FrameBindingTy>;
352352

353353
/// Populates the given SmallVector with the bindings in the callee's stack

clang/lib/StaticAnalyzer/Core/Store.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ StoreRef StoreManager::enterStackFrame(Store OldStore,
5252
Call.getInitialStackFrameContents(LCtx, InitialBindings);
5353

5454
for (const auto &I : InitialBindings)
55-
Store = Bind(Store.getStore(), I.first, I.second);
55+
Store = Bind(Store.getStore(), I.first.castAs<Loc>(), I.second);
5656

5757
return Store;
5858
}

0 commit comments

Comments
 (0)