[llvm] r309818 - Assert that the offset in MachineLocation::set() is always 0. (NFC)

Adrian Prantl via llvm-commits llvm-commits at lists.llvm.org
Wed Aug 2 07:45:50 PDT 2017


Author: adrian
Date: Wed Aug  2 07:45:50 2017
New Revision: 309818

URL: http://llvm.org/viewvc/llvm-project?rev=309818&view=rev
Log:
Assert that the offset in MachineLocation::set() is always 0. (NFC)

Modified:
    llvm/trunk/include/llvm/MC/MachineLocation.h

Modified: llvm/trunk/include/llvm/MC/MachineLocation.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/MC/MachineLocation.h?rev=309818&r1=309817&r2=309818&view=diff
==============================================================================
--- llvm/trunk/include/llvm/MC/MachineLocation.h (original)
+++ llvm/trunk/include/llvm/MC/MachineLocation.h Wed Aug  2 07:45:50 2017
@@ -67,6 +67,7 @@ public:
     IsRegister = false;
     Register = R;
     Offset = O;
+    assert(O == 0 && "offset is expected to always be zero");
   }
 };
 




More information about the llvm-commits mailing list