From 711ba457e2d14bc069a10829843d256d8d5263ee Mon Sep 17 00:00:00 2001 From: Cristian Cadar Date: Mon, 26 Apr 2010 09:46:01 +0000 Subject: Applied patch submitted by Peter Collingbourne: "Some parts of the KLEE source code do not conform to the C++ standard, specifically [basic.scope.local]. gcc accepts the code due to a bug [1] but some other compilers (e.g. those based on EDG, such as icc) do not. This patch fixes the code in question to conform to the standard. [1] http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18770" git-svn-id: https://llvm.org/svn/llvm-project/klee/trunk@102328 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Core/ExecutorUtil.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib/Core/ExecutorUtil.cpp') diff --git a/lib/Core/ExecutorUtil.cpp b/lib/Core/ExecutorUtil.cpp index d2878878..5164e927 100644 --- a/lib/Core/ExecutorUtil.cpp +++ b/lib/Core/ExecutorUtil.cpp @@ -93,11 +93,11 @@ namespace klee { ci->getZExtValue()), Context::get().getPointerWidth()); } else { - const SequentialType *st = cast(*ii); + const SequentialType *set = cast(*ii); ref index = evalConstant(cast(ii.getOperand())); unsigned elementSize = - kmodule->targetData->getTypeStoreSize(st->getElementType()); + kmodule->targetData->getTypeStoreSize(set->getElementType()); index = index->ZExt(Context::get().getPointerWidth()); addend = index->Mul(ConstantExpr::alloc(elementSize, -- cgit 1.4.1