r190971 - Fix CharByteWidth assertion in LiteralSupport.

Eli Friedman eli.friedman at gmail.com
Wed Sep 18 16:23:13 PDT 2013


Author: efriedma
Date: Wed Sep 18 18:23:13 2013
New Revision: 190971

URL: http://llvm.org/viewvc/llvm-project?rev=190971&view=rev
Log:
Fix CharByteWidth assertion in LiteralSupport.

Patch by Eelis van der Weegen.

Modified:
    cfe/trunk/lib/Lex/LiteralSupport.cpp

Modified: cfe/trunk/lib/Lex/LiteralSupport.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Lex/LiteralSupport.cpp?rev=190971&r1=190970&r2=190971&view=diff
==============================================================================
--- cfe/trunk/lib/Lex/LiteralSupport.cpp (original)
+++ cfe/trunk/lib/Lex/LiteralSupport.cpp Wed Sep 18 18:23:13 2013
@@ -336,7 +336,7 @@ static void EncodeUCNEscape(const char *
     return;
   }
 
-  assert((CharByteWidth == 1 || CharByteWidth == 2 || CharByteWidth) &&
+  assert((CharByteWidth == 1 || CharByteWidth == 2 || CharByteWidth == 4) &&
          "only character widths of 1, 2, or 4 bytes supported");
 
   (void)UcnLen;





More information about the cfe-commits mailing list