diff options
Diffstat (limited to 'clang/Parse/ParseExpr.cpp')
| -rw-r--r-- | clang/Parse/ParseExpr.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/clang/Parse/ParseExpr.cpp b/clang/Parse/ParseExpr.cpp index d0964911fca..d5ffc627ada 100644 --- a/clang/Parse/ParseExpr.cpp +++ b/clang/Parse/ParseExpr.cpp @@ -398,6 +398,7 @@ Parser::ParseRHSOfBinaryExpression(ExprResult LHS, unsigned MinPrec) { /// identifier /// constant /// string-literal +/// [C++] boolean-literal [C++ 2.13.5] /// '(' expression ')' /// '__func__' [C99 6.4.2.2] /// [GNU] '__FUNCTION__' @@ -484,6 +485,10 @@ Parser::ExprResult Parser::ParseCastExpression(bool isUnaryExpression) { // These can be followed by postfix-expr pieces. return ParsePostfixExpressionSuffix(Res); + case tok::kw_true: + case tok::kw_false: + return ParseCXXBoolLiteral(); + case tok::identifier: { // primary-expression: identifier // constant: enumeration-constant // Consume the identifier so that we can see if it is followed by a '('. |

