[llvm] r299312 - [WASM] Remove a set but never used variable.
Davide Italiano via llvm-commits
llvm-commits at lists.llvm.org
Sat Apr 1 12:40:52 PDT 2017
Author: davide
Date: Sat Apr 1 14:40:51 2017
New Revision: 299312
URL: http://llvm.org/viewvc/llvm-project?rev=299312&view=rev
Log:
[WASM] Remove a set but never used variable.
Modified:
llvm/trunk/lib/Object/WasmObjectFile.cpp
Modified: llvm/trunk/lib/Object/WasmObjectFile.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Object/WasmObjectFile.cpp?rev=299312&r1=299311&r2=299312&view=diff
==============================================================================
--- llvm/trunk/lib/Object/WasmObjectFile.cpp (original)
+++ llvm/trunk/lib/Object/WasmObjectFile.cpp Sat Apr 1 14:40:51 2017
@@ -458,11 +458,8 @@ Error WasmObjectFile::parseGlobalSection
wasm::WasmGlobal Global;
Global.Type = readVarint7(Ptr);
Global.Mutable = readVaruint1(Ptr);
- size_t offset = Ptr - getPtr(0);
- if (Error Err = readInitExpr(Global.InitExpr, Ptr)) {
- offset = Ptr - getPtr(0);
+ if (Error Err = readInitExpr(Global.InitExpr, Ptr))
return Err;
- }
Globals.push_back(Global);
}
if (Ptr != End)
More information about the llvm-commits
mailing list