diff options
author | Jose <jose@zeroc.com> | 2019-06-21 22:22:14 +0200 |
---|---|---|
committer | Jose <jose@zeroc.com> | 2019-06-21 22:22:14 +0200 |
commit | d1b7c66fab777fe72e5cf77fd284218e2080b017 (patch) | |
tree | b48615b2d9d2f59195c8a560e07585b9cbb77cb5 /cpp/src/IceUtil/StringUtil.cpp | |
parent | Add ice_isFixed - Close #356 (diff) | |
download | ice-d1b7c66fab777fe72e5cf77fd284218e2080b017.tar.bz2 ice-d1b7c66fab777fe72e5cf77fd284218e2080b017.tar.xz ice-d1b7c66fab777fe72e5cf77fd284218e2080b017.zip |
Enable -Wconversion with clang - Close #363
Diffstat (limited to 'cpp/src/IceUtil/StringUtil.cpp')
-rw-r--r-- | cpp/src/IceUtil/StringUtil.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/cpp/src/IceUtil/StringUtil.cpp b/cpp/src/IceUtil/StringUtil.cpp index f78617c41dd..03cd429e622 100644 --- a/cpp/src/IceUtil/StringUtil.cpp +++ b/cpp/src/IceUtil/StringUtil.cpp @@ -22,11 +22,11 @@ toHexDigit(Byte b) assert(b < 16); if(b < 10) { - return '0' + b; + return static_cast<char>('0' + b); } else { - return 'a' - 10 + b; + return static_cast<char>('a' - 10 + b); } } @@ -289,7 +289,7 @@ checkChar(const string& s, string::size_type pos) ostr << " has invalid ordinal value " << static_cast<int>(c); throw IllegalArgumentException(__FILE__, __LINE__, ostr.str()); } - return c; + return static_cast<char>(c); } // |