1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-26 12:43:36 +01:00

Convert some old C-style casts to C++ style.

llvm-svn: 19868
This commit is contained in:
Reid Spencer 2005-01-28 07:22:20 +00:00
parent 4cfda09ee9
commit dab05f06a4

View File

@ -29,7 +29,7 @@ static inline std::string utohexstr(uint64_t X) {
if (X == 0) *--BufPtr = '0'; // Handle special case...
while (X) {
unsigned char Mod = (unsigned char)X & 15;
unsigned char Mod = static_cast<unsigned char>(X) & 15;
if (Mod < 10)
*--BufPtr = '0' + Mod;
else
@ -109,7 +109,7 @@ static inline std::string LowercaseString(const std::string &S) {
std::string result(S);
for (unsigned i = 0; i < S.length(); ++i)
if (isupper(result[i]))
result[i] = (char)tolower(result[i]);
result[i] = char(tolower(result[i]));
return result;
}