/external/clang/lib/Rewrite/ |
TokenRewriter.cpp | 35 while (RawTok.isNot(tok::eof)) { 37 if (Tok.is(tok::raw_identifier)) { 40 PP.LookUpIdentifierInfo(Tok); 87 Token Tok; 88 Tok.startToken(); 90 Tok.setLocation(ScratchBuf->getToken(Val, Len, Spelling)); 91 Tok.setLength(Len); 94 // set kind to tok::unknown. 95 Tok.setKind(tok::unknown) [all...] |
HTMLRewrite.cpp | 372 Token Tok; 373 L.LexFromRawLexer(Tok); 375 while (Tok.isNot(tok::eof)) { 378 unsigned TokOffs = SM.getFileOffset(Tok.getLocation()); 379 unsigned TokLen = Tok.getLength(); 380 switch (Tok.getKind()) { 382 case tok::identifier: 383 llvm_unreachable("tok::identifier in raw lexing mode!"); 384 case tok::raw_identifier: [all...] |
/external/clang/lib/Lex/ |
MacroArgs.cpp | 105 for (; ArgPtr->isNot(tok::eof); ++ArgPtr) 121 if (Result->is(tok::eof)) 135 for (; ArgTok->isNot(tok::eof); ++ArgTok) 174 Token &Tok = Result.back(); 175 PP.Lex(Tok); 176 } while (Result.back().isNot(tok::eof)); 199 Token Tok; 200 Tok.startToken(); 201 Tok.setKind(Charify ? tok::char_constant : tok::string_literal) [all...] |
PPExpressions.cpp | 91 if (PeekTok.is(tok::l_paren)) { 97 if (PeekTok.is(tok::code_completion)) { 130 if (PeekTok.isNot(tok::r_paren)) { 162 if (PeekTok.is(tok::code_completion)) { 183 Result.Val = II->getTokenID() == tok::kw_true; 194 case tok::eod: 195 case tok::r_paren: 199 case tok::numeric_constant: { 254 case tok::char_constant: // 'x' 255 case tok::wide_char_constant: { // L'x [all...] |
TokenLexer.cpp | 26 void TokenLexer::Init(Token &Tok, SourceLocation ELEnd, MacroArgs *Actuals) { 31 Macro = PP.getMacroInfo(Tok.getIdentifierInfo()); 35 ExpandLocStart = Tok.getLocation(); 37 AtStartOfLine = Tok.isAtStartOfLine(); 38 HasLeadingSpace = Tok.hasLeadingSpace(); 50 assert((Tokens[0].getLocation().isFileID() || Tokens[0].is(tok::comment)) && 142 if (CurTok.is(tok::hash) || CurTok.is(tok::hashat)) { 152 if (CurTok.is(tok::hash)) // Stringify 198 !ResultToks.empty() && ResultToks.back().is(tok::hashhash) [all...] |
PPMacroExpansion.cpp | 342 Token Tok; 346 LexUnexpandedToken(Tok); 347 assert(Tok.is(tok::l_paren) && "Error computing l-paren-ness?"); 355 while (Tok.isNot(tok::r_paren)) { 356 assert((Tok.is(tok::l_paren) || Tok.is(tok::comma)) & [all...] |
Pragma.cpp | 80 Token &Tok) { 83 PP.LexUnexpandedToken(Tok); 87 = FindHandler(Tok.getIdentifierInfo() ? Tok.getIdentifierInfo()->getName() 91 PP.Diag(Tok, diag::warn_pragma_ignored); 96 Handler->HandlePragma(PP, Introducer, Tok); 109 Token Tok; 110 PragmaHandlers->HandlePragma(*this, PragmaIntroducerKind(Introducer), Tok); 129 Token &Tok) 131 Failed(false), OutTok(Tok) { [all...] |
ModuleMap.cpp | 518 MMToken Tok; 556 Tok.clear(); 566 SourceLocation Result = Tok.getLocation(); 567 Tok.clear(); 571 Tok.Location = LToken.getLocation().getRawEncoding(); 573 case tok::raw_identifier: 574 Tok.StringData = LToken.getRawIdentifierData(); 575 Tok.StringLength = LToken.getLength(); 576 Tok.Kind = llvm::StringSwitch<MMToken::TokenKind>(Tok.getString() [all...] |
PPDirectives.cpp | 86 /// current line until the tok::eod token is found. 91 assert(Tmp.isNot(tok::eof) && "EOF seen while discarding directive tokens"); 92 } while (Tmp.isNot(tok::eod)); 104 if (MacroNameTok.is(tok::code_completion)) { 112 if (MacroNameTok.is(tok::eod)) { 139 } else if (isDefineUndef && II->getPPKeywordID() == tok::pp_defined) { 155 // token kind to tok::eod. 156 MacroNameTok.setKind(tok::eod); 160 /// CheckEndOfDirective - Ensure that the next token is a tok::eod token. If 175 while (Tmp.is(tok::comment)) // Skip comments in -C mode [all...] |
Lexer.cpp | 46 bool Token::isObjCAtKeyword(tok::ObjCKeywordKind objcKey) const { 53 tok::ObjCKeywordKind Token::getObjCKeywordID() const { 55 return specId ? specId->getObjCKeywordID() : tok::objc_not_keyword; 289 std::string Lexer::getSpelling(const Token &Tok, const SourceManager &SourceMgr, 291 assert((int)Tok.getLength() >= 0 && "Token character range is bogus!"); 295 const char* TokStart = SourceMgr.getCharacterData(Tok.getLocation(), 302 if (!Tok.needsCleaning()) 303 return std::string(TokStart, TokStart+Tok.getLength()); 306 Result.reserve(Tok.getLength()); 309 for (const char *Ptr = TokStart, *End = TokStart+Tok.getLength() [all...] |
/external/clang/lib/Frontend/ |
FrontendActions.cpp | 372 while (RawTok.isNot(tok::eof)) { 382 Token Tok; 385 PP.Lex(Tok); 386 PP.DumpToken(Tok, true); 388 } while (Tok.isNot(tok::eof)); 412 Token Tok; 416 PP.Lex(Tok); 417 } while (Tok.isNot(tok::eof)) [all...] |
PrintPreprocessedOutput.cpp | 133 bool HandleFirstTokOnLine(Token &Tok); 143 const Token &Tok) { 144 return ConcatInfo.AvoidConcat(PrevPrevTok, PrevTok, Tok); 414 bool PrintPPOutputPPCallbacks::HandleFirstTokOnLine(Token &Tok) { 417 if (!MoveToLine(Tok.getLocation())) 422 unsigned ColNo = SM.getExpansionColumnNumber(Tok.getLocation()); 430 if (ColNo <= 1 && Tok.is(tok::hash)) 479 while (PragmaTok.isNot(tok::eod)) { 492 static void PrintPreprocessedTokens(Preprocessor &PP, Token &Tok, [all...] |
VerifyDiagnosticConsumer.cpp | 356 Token Tok; 357 Tok.setKind(tok::comment); 358 while (Tok.isNot(tok::eof)) { 359 RawLex.Lex(Tok); 360 if (!Tok.is(tok::comment)) continue; 362 std::string Comment = PP.getSpelling(Tok); 366 ParseDirective(&Comment[0], Comment.size(), ED, PP, Tok.getLocation()) [all...] |
CacheTokens.cpp | 282 Token Tok; 285 L.LexFromRawLexer(Tok); 288 if ((Tok.isAtStartOfLine() || Tok.is(tok::eof)) && 293 // 'Tok' when we exit this branch. 294 Token Tmp = Tok; 295 Tmp.setKind(tok::eod); 302 if (Tok.is(tok::raw_identifier)) [all...] |
/external/llvm/lib/TableGen/ |
TGLexer.cpp | 294 tgtok::TokKind Tok = LexToken(); 295 if (Tok == tgtok::Error) return true; 296 if (Tok != tgtok::StrVal) {
|
/external/llvm/tools/llvm-mc/ |
llvm-mc.cpp | 253 AsmToken Tok = Lexer.getTok(); 255 switch (Tok.getKind()) { 320 Out->os().write_escaped(Tok.getString());
|
/frameworks/compile/slang/ |
slang.cpp | 402 clang::Token Tok; 405 mPP->Lex(Tok); 406 } while (Tok.isNot(clang::tok::eof));
|
/external/clang/lib/Parse/ |
ParsePragma.cpp | 26 assert(Tok.is(tok::annot_pragma_unused)); 28 Actions.ActOnPragmaUnused(Tok, getCurScope(), UnusedLoc); 33 assert(Tok.is(tok::annot_pragma_vis)); 35 static_cast<IdentifierInfo *>(Tok.getAnnotationValue()); 49 assert(Tok.is(tok::annot_pragma_pack)); 51 static_cast<PragmaPackInfo *>(Tok.getAnnotationValue()); 65 Token Tok; [all...] |
Parser.cpp | 39 Tok.setKind(tok::eof); 88 const Token &Tok = P.getCurToken(); 89 if (Tok.is(tok::eof)) { 94 if (Tok.getLocation().isInvalid()) { 100 Tok.getLocation().print(OS, PP.getSourceManager()); 101 if (Tok.isAnnotation()) 104 OS << ": current parser token '" << PP.getSpelling(Tok) << "'\n"; 112 DiagnosticBuilder Parser::Diag(const Token &Tok, unsigned DiagID) [all...] |
/external/llvm/utils/TableGen/ |
CodeGenInstruction.cpp | 202 std::string Tok = CStr.substr(start, wpos - start); 203 if (Tok == "@earlyclobber") {
|
AsmMatcherEmitter.cpp | 789 StringRef Tok = AsmOperands[i].Token; 790 if (Tok[0] == '$' && Tok.find(':') != StringRef::npos) 792 "matchable with operand modifier '" + Tok.str() + 797 if (Tok[0] == '$' && !OperandNames.insert(Tok).second) { 800 "ERROR: matchable with tied operand '" + Tok.str() + 807 << Tok.str() << "'\n"; 822 StringRef Tok = AsmOperands[OperandNo].Token; 824 std::string LoweredTok = Tok.lower() [all...] |
/external/llvm/lib/Target/MBlaze/AsmParser/ |
MBlazeAsmParser.cpp | 87 } Tok; 122 Tok = o.Tok; 214 return StringRef(Tok.Data, Tok.Length); 221 Op->Tok.Data = Str.data(); 222 Op->Tok.Length = Str.size();
|
/external/llvm/lib/Target/X86/AsmParser/ |
X86AsmParser.cpp | 163 } Tok; 197 return StringRef(Tok.Data, Tok.Length); 201 Tok.Data = Value.data(); 202 Tok.Length = Value.size(); 402 Res->Tok.Data = Str.data(); 403 Res->Tok.Length = Str.size(); 487 const AsmToken &Tok = Parser.getTok(); 488 if (Tok.isNot(AsmToken::Identifier)) { 491 SMRange(StartLoc, Tok.getEndLoc())) [all...] |
/external/llvm/lib/Support/ |
YAMLParser.cpp | 180 /// others) before the SimpleKey's Tok. 182 TokenQueueT::iterator Tok; 189 return Tok == Other.Tok; 388 void saveSimpleKeyCandidate( TokenQueueT::iterator Tok 732 SK.Tok = TokenQueue.front(); 917 void Scanner::saveSimpleKeyCandidate( TokenQueueT::iterator Tok 922 SK.Tok = Tok; 937 , i->Tok->Range.begin()) [all...] |
/external/clang/include/clang/Parse/ |
Parser.h | 86 /// Tok - The current token we are peeking ahead. All parsing methods assume 88 Token Tok; 211 const Token &getCurToken() const { return Tok; } 271 return Tok.getKind() == tok::l_paren || Tok.getKind() == tok::r_paren; 275 return Tok.getKind() == tok::l_square || Tok.getKind() == tok::r_square [all...] |