From cc19b2fb2e18a1f7b750f658f8b74f8e9fba817a Mon Sep 17 00:00:00 2001 From: "Duncan P. N. Exon Smith" Date: Thu, 22 Jan 2015 03:13:35 +0000 Subject: [PATCH] DIBuilder: Stop abusing DIExpressionIterator::operator*(), NFC This code was confusing, since it created a `DIExpressionIterator` from an invalid start point (although it wasn't wrong: it never actually iterated). Now that the underlying iterator has `getNumber()`, just use it directly. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@226773 91177308-0d34-0410-b5e6-96231b3b80d8 --- include/llvm/IR/DebugInfo.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/llvm/IR/DebugInfo.h b/include/llvm/IR/DebugInfo.h index fc4d95cfc14..f42a8ebd884 100644 --- a/include/llvm/IR/DebugInfo.h +++ b/include/llvm/IR/DebugInfo.h @@ -910,7 +910,7 @@ public: uint64_t getArg(unsigned N) const { auto In = I; std::advance(In, N); - return *DIExpressionIterator(In); + return In.getNumber(); } const DIHeaderFieldIterator& getBase() const { return I; } -- 2.34.1