ParseExpr.cpp (198893) | ParseExpr.cpp (199512) |
---|---|
1//===--- ParseExpr.cpp - Expression Parsing -------------------------------===// 2// 3// The LLVM Compiler Infrastructure 4// 5// This file is distributed under the University of Illinois Open Source 6// License. See LICENSE.TXT for details. 7// 8//===----------------------------------------------------------------------===// --- 327 unchanged lines hidden (view full) --- 336 Diag(OpToken, diag::note_matching) << "?"; 337 return ExprError(); 338 } 339 340 // Eat the colon. 341 ColonLoc = ConsumeToken(); 342 } 343 | 1//===--- ParseExpr.cpp - Expression Parsing -------------------------------===// 2// 3// The LLVM Compiler Infrastructure 4// 5// This file is distributed under the University of Illinois Open Source 6// License. See LICENSE.TXT for details. 7// 8//===----------------------------------------------------------------------===// --- 327 unchanged lines hidden (view full) --- 336 Diag(OpToken, diag::note_matching) << "?"; 337 return ExprError(); 338 } 339 340 // Eat the colon. 341 ColonLoc = ConsumeToken(); 342 } 343 |
344 if ((OpToken.is(tok::periodstar) || OpToken.is(tok::arrowstar)) 345 && Tok.is(tok::identifier)) { 346 CXXScopeSpec SS; 347 if (Actions.getTypeName(*Tok.getIdentifierInfo(), 348 Tok.getLocation(), CurScope, &SS)) { 349 const char *Opc = OpToken.is(tok::periodstar) ? "'.*'" : "'->*'"; 350 Diag(OpToken, diag::err_pointer_to_member_type) << Opc; 351 return ExprError(); 352 } 353 354 } | |
355 // Parse another leaf here for the RHS of the operator. 356 // ParseCastExpression works here because all RHS expressions in C have it 357 // as a prefix, at least. However, in C++, an assignment-expression could 358 // be a throw-expression, which is not a valid cast-expression. 359 // Therefore we need some special-casing here. 360 // Also note that the third operand of the conditional operator is 361 // an assignment-expression in C++. 362 OwningExprResult RHS(Actions); --- 1261 unchanged lines hidden --- | 344 // Parse another leaf here for the RHS of the operator. 345 // ParseCastExpression works here because all RHS expressions in C have it 346 // as a prefix, at least. However, in C++, an assignment-expression could 347 // be a throw-expression, which is not a valid cast-expression. 348 // Therefore we need some special-casing here. 349 // Also note that the third operand of the conditional operator is 350 // an assignment-expression in C++. 351 OwningExprResult RHS(Actions); --- 1261 unchanged lines hidden --- |