Add a comment for r123231.

llvm-svn: 123291
This commit is contained in:
Francois Pichet 2011-01-11 23:38:13 +00:00
parent 43812bfa92
commit c3e73b343c
1 changed files with 2 additions and 0 deletions

View File

@ -2497,6 +2497,8 @@ ExprResult Sema::ActOnNumericConstant(const Token &Tok) {
// Does it fit in a unsigned long long?
if (ResultVal.isIntN(LongLongSize)) {
// Does it fit in a signed long long?
// To be compatible with MSVC, hex integer literals ending with the
// LL or i64 suffix are always signed in Microsoft mode.
if (!Literal.isUnsigned && (ResultVal[LongLongSize-1] == 0 ||
(getLangOptions().Microsoft && Literal.isLongLong)))
Ty = Context.LongLongTy;