[llvm] r251210 - [Support] Add comment to explain why we can't drop NDEBUG.
Davide Italiano via llvm-commits
llvm-commits at lists.llvm.org
Sat Oct 24 15:15:33 PDT 2015
Author: davide
Date: Sat Oct 24 17:15:32 2015
New Revision: 251210
URL: http://llvm.org/viewvc/llvm-project?rev=251210&view=rev
Log:
[Support] Add comment to explain why we can't drop NDEBUG.
Discussed with: Benjamin Kramer.
Modified:
llvm/trunk/include/llvm/Support/UnicodeCharRanges.h
Modified: llvm/trunk/include/llvm/Support/UnicodeCharRanges.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Support/UnicodeCharRanges.h?rev=251210&r1=251209&r2=251210&view=diff
==============================================================================
--- llvm/trunk/include/llvm/Support/UnicodeCharRanges.h (original)
+++ llvm/trunk/include/llvm/Support/UnicodeCharRanges.h Sat Oct 24 17:15:32 2015
@@ -51,6 +51,11 @@ public:
/// the constructor, so it makes sense to create as few UnicodeCharSet
/// instances per each array of ranges, as possible.
#ifdef NDEBUG
+
+ // FIXME: This could use constexpr + static_assert. This way we
+ // may get rid of NDEBUG in this header. Unfortunately there are some
+ // problems to get this working with MSVC 2013. Change this when
+ // the support for MSVC 2013 is dropped.
LLVM_CONSTEXPR UnicodeCharSet(CharRanges Ranges) : Ranges(Ranges) {}
#else
UnicodeCharSet(CharRanges Ranges) : Ranges(Ranges) {
More information about the llvm-commits
mailing list