aboutsummaryrefslogtreecommitdiff
path: root/lib/Parse/ParseExpr.cpp
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2009-10-25 17:16:46 +0000
committerChris Lattner <sabre@nondot.org>2009-10-25 17:16:46 +0000
commit10ca337b1e3684547bd21021a23a566f30fa83b4 (patch)
treec28edb3ea39604c57f50ad9a4a6b59d0dbc26b2c /lib/Parse/ParseExpr.cpp
parentb7c3fd7b493329550c29dec11d31aca4d537e23e (diff)
simplify Sema::getTypeName a bit: if control gets out of the switch,
IIDecl cannot be null. There is no need to check for both C++ mode and presence of CXXRecordDecl. ObjC interfaces can't have ScopeSpecs. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@85057 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Parse/ParseExpr.cpp')
-rw-r--r--lib/Parse/ParseExpr.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Parse/ParseExpr.cpp b/lib/Parse/ParseExpr.cpp
index 8ebb7c01d8..477e6fb005 100644
--- a/lib/Parse/ParseExpr.cpp
+++ b/lib/Parse/ParseExpr.cpp
@@ -345,7 +345,7 @@ Parser::ParseRHSOfBinaryExpression(OwningExprResult LHS, unsigned MinPrec) {
&& Tok.is(tok::identifier)) {
CXXScopeSpec SS;
if (Actions.getTypeName(*Tok.getIdentifierInfo(),
- Tok.getLocation(), CurScope, &SS)) {
+ Tok.getLocation(), CurScope, &SS)) {
const char *Opc = OpToken.is(tok::periodstar) ? "'.*'" : "'->*'";
Diag(OpToken, diag::err_pointer_to_member_type) << Opc;
return ExprError();