DebugInfo: Gut DIExpression
[oota-llvm.git] / lib / CodeGen / AsmPrinter / DebugLocEntry.h
index f50ebae7ba6effe7183df09c8f72eb6b53c169b1..dd7f806e0297f46e2d8f7fff7d16465f177270a9 100644 (file)
@@ -76,7 +76,7 @@ public:
     MachineLocation getLoc() const { return Loc; }
     const MDNode *getVariableNode() const { return Variable; }
     DIVariable getVariable() const { return cast<MDLocalVariable>(Variable); }
-    bool isBitPiece() const { return getExpression().isBitPiece(); }
+    bool isBitPiece() const { return getExpression()->isBitPiece(); }
     DIExpression getExpression() const {
       return cast_or_null<MDExpression>(Expression);
     }
@@ -108,8 +108,7 @@ public:
       DIExpression NextExpr =
           cast_or_null<MDExpression>(Next.Values[0].Expression);
       DIVariable NextVar = cast_or_null<MDLocalVariable>(Next.Values[0].Variable);
-      if (Var == NextVar && Expr.isBitPiece() &&
-          NextExpr.isBitPiece()) {
+      if (Var == NextVar && Expr->isBitPiece() && NextExpr->isBitPiece()) {
         addValues(Next.Values);
         End = Next.End;
         return true;
@@ -192,8 +191,8 @@ inline bool operator==(const DebugLocEntry::Value &A,
 /// \brief Compare two pieces based on their offset.
 inline bool operator<(const DebugLocEntry::Value &A,
                       const DebugLocEntry::Value &B) {
-  return A.getExpression().getBitPieceOffset() <
-         B.getExpression().getBitPieceOffset();
+  return A.getExpression()->getBitPieceOffset() <
+         B.getExpression()->getBitPieceOffset();
 }
 
 }