diff options
author | Guy Benyei <guy.benyei@intel.com> | 2013-02-12 21:21:59 +0000 |
---|---|---|
committer | Guy Benyei <guy.benyei@intel.com> | 2013-02-12 21:21:59 +0000 |
commit | 83c74e9fad4442998a780dc7707461713615fd82 (patch) | |
tree | fea31fcb6ba5dc4d108529fe1707cad4fc7eeb4f /llvm/lib/IR/InlineAsm.cpp | |
parent | 4e472b63280f208edf086c843725ec5935baa93f (diff) | |
download | bcm5719-llvm-83c74e9fad4442998a780dc7707461713615fd82.tar.gz bcm5719-llvm-83c74e9fad4442998a780dc7707461713615fd82.zip |
Add static cast to unsigned char whenever a character classification function is called with a signed char argument, in order to avoid assertions in Windows Debug configuration.
llvm-svn: 175006
Diffstat (limited to 'llvm/lib/IR/InlineAsm.cpp')
-rw-r--r-- | llvm/lib/IR/InlineAsm.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/IR/InlineAsm.cpp b/llvm/lib/IR/InlineAsm.cpp index 10d281bca89..9f2a9fea4b9 100644 --- a/llvm/lib/IR/InlineAsm.cpp +++ b/llvm/lib/IR/InlineAsm.cpp @@ -151,10 +151,10 @@ bool InlineAsm::ConstraintInfo::Parse(StringRef Str, if (ConstraintEnd == E) return true; // "{foo" pCodes->push_back(std::string(I, ConstraintEnd+1)); I = ConstraintEnd+1; - } else if (isdigit(*I)) { // Matching Constraint + } else if (isdigit(static_cast<unsigned char>(*I))) { // Matching Constraint // Maximal munch numbers. StringRef::iterator NumStart = I; - while (I != E && isdigit(*I)) + while (I != E && isdigit(static_cast<unsigned char>(*I))) ++I; pCodes->push_back(std::string(NumStart, I)); unsigned N = atoi(pCodes->back().c_str()); |