From: Benjamin Kramer Date: Sat, 21 Apr 2012 10:51:42 +0000 (+0000) Subject: YAMLParser: silence warning about tautological comparison on unsigned-char platforms. X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=2ddb84506c99760e977f25bcac9273431f7f0816;p=oota-llvm.git YAMLParser: silence warning about tautological comparison on unsigned-char platforms. No functionality change. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@155280 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/Support/YAMLParser.cpp b/lib/Support/YAMLParser.cpp index 330519f3019..9b5896de7aa 100644 --- a/lib/Support/YAMLParser.cpp +++ b/lib/Support/YAMLParser.cpp @@ -658,7 +658,7 @@ std::string yaml::escape(StringRef Input) { EscapedInput += "\\r"; else if (*i == 0x1B) EscapedInput += "\\e"; - else if (*i >= 0 && *i < 0x20) { // Control characters not handled above. + else if ((unsigned char)*i < 0x20) { // Control characters not handled above. std::string HexStr = utohexstr(*i); EscapedInput += "\\x" + std::string(2 - HexStr.size(), '0') + HexStr; } else if (*i & 0x80) { // UTF-8 multiple code unit subsequence.