[llvm] r236662 - Remove unnecessary #ifndef NDEBUG guard around assert. NFC.

Pete Cooper peter_cooper at apple.com
Wed May 6 15:55:46 PDT 2015


Author: pete
Date: Wed May  6 17:55:46 2015
New Revision: 236662

URL: http://llvm.org/viewvc/llvm-project?rev=236662&view=rev
Log:
Remove unnecessary #ifndef NDEBUG guard around assert.  NFC.

Found by Hal Finkel in the review of AttributeSets.  http://lists.cs.uiuc.edu/pipermail/llvm-commits/Week-of-Mon-20150504/275058.html

Modified:
    llvm/trunk/lib/IR/Attributes.cpp

Modified: llvm/trunk/lib/IR/Attributes.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/IR/Attributes.cpp?rev=236662&r1=236661&r2=236662&view=diff
==============================================================================
--- llvm/trunk/lib/IR/Attributes.cpp (original)
+++ llvm/trunk/lib/IR/Attributes.cpp Wed May  6 17:55:46 2015
@@ -819,12 +819,10 @@ AttributeSet AttributeSet::removeAttribu
   if (!pImpl) return AttributeSet();
   if (!Attrs.pImpl) return *this;
 
-#ifndef NDEBUG
   // FIXME it is not obvious how this should work for alignment.
   // For now, say we can't pass in alignment, which no current use does.
   assert(!Attrs.hasAttribute(Index, Attribute::Alignment) &&
          "Attempt to change alignment!");
-#endif
 
   // Add the attribute slots before the one we're trying to add.
   SmallVector<AttributeSet, 4> AttrSet;





More information about the llvm-commits mailing list