Lines Matching refs:Tok

33   assert((Tok.is(tok::l_brace) || Tok.is(tok::colon) || Tok.is(tok::kw_try) ||
34 Tok.is(tok::equal)) &&
67 if (Tok.is(tok::equal)) {
77 if (Tok.is(tok::kw_delete)) {
78 Diag(Tok, getLangOpts().CPlusPlus0x ?
85 } else if (Tok.is(tok::kw_default)) {
86 Diag(Tok, getLangOpts().CPlusPlus0x ?
96 if (Tok.is(tok::comma)) {
145 tok::TokenKind kind = Tok.getKind();
153 if (Tok.is(tok::semi))
165 while (Tok.is(tok::kw_catch)) {
187 assert((Tok.is(tok::l_brace) || Tok.is(tok::equal)) &&
195 tok::TokenKind kind = Tok.getKind();
197 Toks.push_back(Tok);
203 Toks.push_back(Tok);
219 Eof.setLocation(Tok.getLocation());
305 SourceLocation origLoc = Tok.getLocation();
308 Toks->push_back(Tok); // So that the current token doesn't get lost
315 assert(Tok.is(tok::equal) && "Default argument not starting with '='");
325 if (getLangOpts().CPlusPlus0x && Tok.is(tok::l_brace)) {
326 Diag(Tok, diag::warn_cxx98_compat_generalized_initializer_lists);
333 if (Tok.is(tok::cxx_defaultarg_end))
336 Diag(Tok.getLocation(), diag::err_default_arg_unparsed);
342 Tok.getLocation()) &&
346 while (Tok.getLocation() != origLoc && Tok.isNot(tok::eof))
385 SourceLocation origLoc = Tok.getLocation();
390 LM.Toks.push_back(Tok);
395 assert((Tok.is(tok::l_brace) || Tok.is(tok::colon) || Tok.is(tok::kw_try))
403 if (Tok.is(tok::kw_try)) {
406 Tok.getLocation()) &&
410 while (Tok.getLocation() != origLoc && Tok.isNot(tok::eof))
414 if (Tok.is(tok::colon)) {
418 if (!Tok.is(tok::l_brace)) {
421 while (Tok.getLocation() != origLoc && Tok.isNot(tok::eof))
430 if (Tok.getLocation() != origLoc) {
436 if (PP.getSourceManager().isBeforeInTranslationUnit(Tok.getLocation(),
438 while (Tok.getLocation() != origLoc && Tok.isNot(tok::eof))
490 MI.Toks.push_back(Tok);
504 if (Tok.isNot(tok::eof)) {
507 EndLoc = Tok.getLocation();
512 while (Tok.isNot(tok::eof))
532 if (Tok.is(T1) || Tok.is(T2)) {
534 Toks.push_back(Tok);
540 switch (Tok.getKind()) {
547 Toks.push_back(Tok);
553 Toks.push_back(Tok);
559 Toks.push_back(Tok);
572 Toks.push_back(Tok);
578 Toks.push_back(Tok);
584 Toks.push_back(Tok);
589 Toks.push_back(Tok);
598 Toks.push_back(Tok);
607 Toks.push_back(Tok);
622 if (Tok.is(tok::kw_try)) {
623 Toks.push_back(Tok);
627 if (Tok.is(tok::colon)) {
629 Toks.push_back(Tok);
632 while (Tok.is(tok::identifier) || Tok.is(tok::coloncolon)) {
633 if (Tok.is(tok::eof) || Tok.is(tok::semi))
634 return Diag(Tok.getLocation(), diag::err_expected_lbrace);
640 return Diag(Tok.getLocation(), diag::err_expected_lparen);
642 tok::TokenKind kind = Tok.getKind();
643 Toks.push_back(Tok);
645 SourceLocation LOpen = Tok.getLocation();
661 Diag(Tok, IsLParen ? diag::err_expected_rparen :
668 if (Tok.is(tok::ellipsis)) {
669 Toks.push_back(Tok);
674 if (Tok.is(tok::comma)) {
675 Toks.push_back(Tok);
677 } else if (Tok.isNot(tok::l_brace)) {
690 if (Tok.isNot(tok::l_brace)) {
692 return Diag(Tok.getLocation(), diag::err_expected_lbrace_or_comma);
693 return Diag(Tok.getLocation(), diag::err_expected_lbrace);
696 Toks.push_back(Tok);