Home | History | Annotate | Download | only in Parse

Lines Matching refs:Tok

28   switch (Tok.getKind()) {
32 case tok::period: // designator: '.' identifier
35 case tok::l_square: { // designator: array-designator
43 case tok::equal:
44 case tok::r_square:
48 case tok::amp:
49 case tok::kw_this:
50 case tok::identifier:
64 case tok::identifier: // designation: identifier ':'
65 return PP.LookAhead(0).is(tok::colon);
87 tok::TokenKind Kind = Tok.getKind();
91 return Kind == tok::equal;
137 if (Tok.is(tok::identifier)) {
138 const IdentifierInfo *FieldName = Tok.getIdentifierInfo();
146 assert(Tok.is(tok::colon) && "MayBeDesignationStart not working properly!");
165 while (Tok.is(tok::period) || Tok.is(tok::l_square)) {
166 if (Tok.is(tok::period)) {
170 if (Tok.isNot(tok::identifier)) {
171 Diag(Tok.getLocation(), diag::err_expected_field_designator);
175 Desig.AddDesignator(Designator::getField(Tok.getIdentifierInfo(), DotLoc,
176 Tok.getLocation()));
182 assert(Tok.is(tok::l_square) && "Unexpected token!");
203 BalancedDelimiterTracker T(*this, tok::l_square);
215 if (Tok.is(tok::identifier) && Tok.getIdentifierInfo() == Ident_super &&
216 NextToken().isNot(tok::period) &&
229 SkipUntil(tok::r_square, StopAtSemi);
248 } else if (getLangOpts().ObjC1 && Tok.is(tok::identifier)) {
249 IdentifierInfo *II = Tok.getIdentifierInfo();
250 SourceLocation IILoc = Tok.getLocation();
257 NextToken().is(tok::period), ReceiverType)) {
269 SkipUntil(tok::r_square, StopAtSemi);
274 if (Tok.is(tok::less)) {
281 SkipUntil(tok::r_square, StopAtSemi);
311 SkipUntil(tok::r_square, StopAtSemi);
320 if (getLangOpts().ObjC1 && Tok.isNot(tok::ellipsis) &&
321 Tok.isNot(tok::r_square)) {
322 CheckArrayDesignatorSyntax(*this, Tok.getLocation(), Desig);
330 if (Tok.isNot(tok::ellipsis)) {
334 Diag(Tok, diag::ext_gnu_array_range);
339 SkipUntil(tok::r_square, StopAtSemi);
359 if (Tok.is(tok::equal)) {
372 Diag(Tok, diag::ext_gnu_missing_equal_designator)
373 << FixItHint::CreateInsertion(Tok.getLocation(), "= ");
374 return Actions.ActOnDesignatedInitializer(Desig, Tok.getLocation(),
378 Diag(Tok, diag::err_expected_equal_designator);
398 BalancedDelimiterTracker T(*this, tok::l_brace);
406 if (Tok.is(tok::r_brace)) {
418 if (getLangOpts().MicrosoftExt && (Tok.is(tok::kw___if_exists) ||
419 Tok.is(tok::kw___if_not_exists))) {
421 if (Tok.isNot(tok::comma)) break;
424 if (Tok.is(tok::r_brace)) break;
438 if (Tok.is(tok::ellipsis))
457 if (Tok.isNot(tok::comma)) {
458 SkipUntil(tok::r_brace, StopBeforeMatch);
464 if (Tok.isNot(tok::comma)) break;
470 if (Tok.is(tok::r_brace)) break;
492 BalancedDelimiterTracker Braces(*this, tok::l_brace);
494 Diag(Tok, diag::err_expected) << tok::l_brace;
523 if (Tok.is(tok::ellipsis))
532 if (Tok.is(tok::comma)) {
537 if (Tok.is(tok::r_brace))