Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(452)

Unified Diff: lib/IR/Constants.cpp

Issue 14262011: PNaCl: Add ReplacePtrsWithInts pass for stripping out pointer types (Closed) Base URL: http://git.chromium.org/native_client/pnacl-llvm.git@master
Patch Set: Review: cleanup Created 7 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: lib/IR/Constants.cpp
diff --git a/lib/IR/Constants.cpp b/lib/IR/Constants.cpp
index 8093a09749fb1d702461cd1de72601a02f52fa0f..f5442063f478362b9dc9e4e717fabe57b859a67d 100644
--- a/lib/IR/Constants.cpp
+++ b/lib/IR/Constants.cpp
@@ -1371,7 +1371,7 @@ void BlockAddress::replaceUsesOfWithOnConstant(Value *From, Value *To, Use *U) {
BasicBlock *NewBB = getBasicBlock();
if (U == &Op<0>())
- NewF = cast<Function>(To);
+ NewF = cast<Function>(To->stripPointerCasts());
Derek Schuff 2013/05/17 23:16:05 LOCALMOD with comment?
Mark Seaborn 2013/05/20 15:08:12 Done: LOCALMOD comment added.
else
NewBB = cast<BasicBlock>(To);

Powered by Google App Engine
This is Rietveld 408576698