/external/chromium_org/third_party/closure_linter/closure_linter/ |
tokenutil_test.py | 28 from closure_linter import tokenutil namespace 49 self.assertEquals([a, b, c, d], tokenutil.GetTokenRange(a, d)) 52 self.assertRaises(Exception, lambda: tokenutil.GetTokenRange(a, e)) 76 tokenutil.TokensToString([a, b, c, d, e])) 80 tokenutil.TokensToString([d, e, a, b, c]), 99 tokenutil.GetPreviousCodeToken(_GetTokenStartingWith('start1'))) 103 tokenutil.GetPreviousCodeToken(_GetTokenStartingWith('end1')).string) 120 tokenutil.GetNextCodeToken(_GetTokenStartingWith('start1')).string) 124 tokenutil.GetNextCodeToken(_GetTokenStartingWith('end1'))) 144 tokenutil.GetIdentifierStart(_GetTokenStartingWith('end1')).string [all...] |
requireprovidesorter.py | 32 from closure_linter import tokenutil namespace 126 tokenutil.DeleteToken(i) 138 tokenutil.DeleteToken(i) 148 tokenutil.InsertTokenBefore(i, rest_of_file) 150 tokenutil.InsertTokenAfter(i, insert_after) 198 name = tokenutil.GetStringAfterToken(token) 233 object_name = tokenutil.GetStringAfterToken(token) 238 previous_first_token = tokenutil.GetFirstTokenInPreviousLine(first_token) 242 previous_first_token = tokenutil.GetFirstTokenInPreviousLine( 246 last_token = tokenutil.GetLastTokenInSameLine(token [all...] |
javascriptstatetracker.py | 22 from closure_linter import tokenutil namespace 123 last_code = tokenutil.SearchExcept(token, Type.NON_CODE_TYPES, reverse=True) 154 if tokenutil.GoogScopeOrNoneFromStartBlock(start_token):
|
error_fixer.py | 31 from closure_linter import tokenutil namespace 155 tokenutil.InsertTokenAfter(semicolon_token, token) 181 tokenutil.InsertSpaceTokenAfter(token.previous) 183 tokenutil.InsertSpaceTokenAfter(token) 195 tokenutil.InsertBlankLineAfter(token.previous) 197 tokenutil.InsertBlankLineAfter(token) 206 # TODO(user): Add an insertBefore method to tokenutil. 221 tokenutil.InsertBlankLineAfter(token.previous) 225 end_quote = tokenutil.Search(token, Type.DOUBLE_QUOTE_STRING_END) 233 tokenutil.InsertTokenAfter(single_quote_start, token [all...] |
scopeutil.py | 26 from closure_linter import tokenutil namespace 143 statement_tokens = tokenutil.GetTokenRange(context.start_token, 172 return alias.string, tokenutil.GetIdentifierForToken(symbol)
|
closurizednamespacesinfo.py | 30 from closure_linter import tokenutil namespace 140 namespace = tokenutil.GetStringAfterToken(token) 166 namespace = tokenutil.GetStringAfterToken(token) 295 whole_identifier_string = tokenutil.GetIdentifierForToken(token) 306 namespace = tokenutil.GetStringAfterToken(token) 321 namespace = tokenutil.GetStringAfterToken(token) 339 for t in tokenutil.GetAllTokensInSameLine(token): 368 start_token = tokenutil.GetIdentifierStart(token) 371 identifier = tokenutil.GetIdentifierForToken(start_token) 394 doc_start = tokenutil.Search(token, TokenType.DOC_START_BRACE [all...] |
statetracker.py | 26 from closure_linter import tokenutil namespace 182 brace = tokenutil.SearchUntil(flag_token, [Type.DOC_START_BRACE], 212 tokenutil.Compare(self.name_token, self.type_start_token) > 0): 225 if tokenutil.Compare(self.type_end_token, self.name_token) > 0: 234 interesting_token = tokenutil.Search(search_start_token, 292 brace = tokenutil.SearchUntil(token, [Type.DOC_START_BRACE], 373 return tokenutil.TokensToString( 388 return tokenutil.GetIdentifierForToken(token) 418 next_code_token = tokenutil.CustomSearch( 430 next_code_token = tokenutil.CustomSearch [all...] |
javascriptstatetracker_test.py | 28 from closure_linter import tokenutil namespace 114 doc_tokens = tokenutil.GetTokenRange(doc.start_token, doc.end_token) 120 tokenutil.TokensToString(comment_tokens).strip())
|
aliaspass.py | 29 from closure_linter import tokenutil namespace 216 identifier = tokenutil.GetIdentifierForToken(token)
|
javascriptlintrules.py | 34 from closure_linter import tokenutil namespace 194 elif flag.name_token and flag.type_end_token and tokenutil.Compare( 240 # NOTE: The tokenutil methods are not used here because of their 358 previous_code = tokenutil.SearchExcept(block_start, 364 previous_previous_code = tokenutil.SearchExcept(previous_code, 412 namespace = tokenutil.GetStringAfterToken(token) 437 tokenutil.GetLastTokenInSameLine(token).next, 447 tokenutil.GetLastTokenInSameLine(token).next, 453 namespace = tokenutil.GetStringAfterToken(token) 463 tokenutil.GetFirstTokenInSameLine(token) [all...] |
indentation.py | 25 from closure_linter import tokenutil namespace 158 goog_scope = tokenutil.GoogScopeOrNoneFromStartBlock(start_token.token) 213 next_code = tokenutil.SearchExcept(token, Type.NON_CODE_TYPES) 215 next_code = tokenutil.SearchExcept(next_code, Type.NON_CODE_TYPES) 412 token = tokenutil.GetFirstTokenInSameLine(token) 472 tokenutil.GoogScopeOrNoneFromStartBlock(token_info.token))
|
closurizednamespacesinfo_test.py | 28 from closure_linter import tokenutil namespace 138 token = tokenutil.Search(token.next, TokenType.IDENTIFIER) 478 tokenutil.GetIdentifierForToken(token)) 481 tokenutil.GetIdentifierForToken(token.next))
|
ecmametadatapass.py | 22 from closure_linter import tokenutil namespace 176 return tokenutil.Compare(context1.start_token, context2.start_token) 342 next_code = tokenutil.SearchExcept(token, TokenType.NON_CODE_TYPES) 364 next_code = tokenutil.SearchExcept(token, TokenType.NON_CODE_TYPES) 493 next_code = tokenutil.SearchExcept(token, TokenType.NON_CODE_TYPES)
|
ecmalintrules.py | 37 from closure_linter import tokenutil namespace 393 for_token = tokenutil.CustomSearch( 653 equal_operator = tokenutil.SearchExcept(token, Type.NON_CODE_TYPES) 654 next_code = tokenutil.SearchExcept(equal_operator, Type.NON_CODE_TYPES) [all...] |
/external/chromium-trace/trace-viewer/third_party/closure_linter/closure_linter/ |
requireprovidesorter.py | 32 from closure_linter import tokenutil namespace 132 tokenutil.DeleteToken(i) 144 tokenutil.DeleteToken(i) 150 tokenutil.InsertTokenAfter(i, insert_after) 196 name = tokenutil.Search(token, Type.STRING_TEXT).string 231 object_name = tokenutil.Search(token, Type.STRING_TEXT).string 236 previous_first_token = tokenutil.GetFirstTokenInPreviousLine(first_token) 239 previous_first_token = tokenutil.GetFirstTokenInPreviousLine( 243 last_token = tokenutil.GetLastTokenInSameLine(token)
|
error_fixer.py | 28 from closure_linter import tokenutil namespace 138 tokenutil.InsertTokenAfter(semicolon_token, token) 146 tokenutil.DeleteToken(token) 161 tokenutil.InsertSpaceTokenAfter(token.previous) 163 tokenutil.InsertSpaceTokenAfter(token) 179 tokenutil.InsertBlankLineAfter(token.previous) 181 tokenutil.InsertBlankLineAfter(token) 185 tokenutil.DeleteToken(token) 190 # TODO(user): Add an insertBefore method to tokenutil. 203 tokenutil.DeleteToken(token.previous [all...] |
javascriptstatetracker.py | 23 from closure_linter import tokenutil namespace 100 last_code = tokenutil.SearchExcept(token, Type.NON_CODE_TYPES, None,
|
closurizednamespacesinfo.py | 28 from closure_linter import tokenutil namespace 138 namespace = tokenutil.Search(token, TokenType.STRING_TEXT).string 167 namespace = tokenutil.Search(token, TokenType.STRING_TEXT).string 309 namespace = tokenutil.Search(token, TokenType.STRING_TEXT).string 324 namespace = tokenutil.Search(token, TokenType.STRING_TEXT).string 361 doc_start = tokenutil.Search(token, TokenType.DOC_START_BRACE) 362 interface = tokenutil.Search(doc_start, TokenType.COMMENT)
|
statetracker.py | 26 from closure_linter import tokenutil namespace 161 brace = tokenutil.SearchUntil(flag_token, [Type.DOC_START_BRACE], 186 tokenutil.Compare(self.name_token, self.type_start_token) > 0): 199 if tokenutil.Compare(self.type_end_token, self.name_token) > 0: 208 interesting_token = tokenutil.Search(search_start_token, 269 brace = tokenutil.SearchUntil(token, [Type.DOC_START_BRACE], 792 f = tokenutil.SearchUntil(t, [Type.DOC_FLAG], [Type.START_DOC_COMMENT], 795 return (tokenutil.Compare(t, f.attached_object.type_start_token) > 0 and 796 tokenutil.Compare(t, f.attached_object.type_end_token) < 0) 885 last_code = tokenutil.SearchExcept(token, Type.NON_CODE_TYPES, None [all...] |
javascriptlintrules.py | 35 from closure_linter import tokenutil namespace 160 elif flag.name_token and flag.type_end_token and tokenutil.Compare( 200 # NOTE: The tokenutil methods are not used here because of their 328 namespace = tokenutil.Search(token, Type.STRING_TEXT).string 343 tokenutil.GetLastTokenInSameLine(token).next, 353 tokenutil.GetLastTokenInSameLine(token).next, 359 namespace = tokenutil.Search(token, Type.STRING_TEXT).string 369 tokenutil.GetFirstTokenInSameLine(token), 385 tokenutil.GetLastTokenInSameLine(token).next,
|
ecmametadatapass.py | 22 from closure_linter import tokenutil namespace 295 next_code = tokenutil.SearchExcept(token, TokenType.NON_CODE_TYPES) 317 next_code = tokenutil.SearchExcept(token, TokenType.NON_CODE_TYPES) 442 next_code = tokenutil.SearchExcept(token, TokenType.NON_CODE_TYPES)
|
indentation.py | 24 from closure_linter import tokenutil namespace 213 next_code = tokenutil.SearchExcept(token, Type.NON_CODE_TYPES) 215 next_code = tokenutil.SearchExcept(next_code, Type.NON_CODE_TYPES) 402 token = tokenutil.GetFirstTokenInSameLine(token)
|
closurizednamespacesinfo_test.py | 26 from closure_linter import tokenutil namespace 134 token = tokenutil.Search(token.next, TokenType.IDENTIFIER)
|
ecmalintrules.py | 34 from closure_linter import tokenutil namespace 342 for_token = tokenutil.CustomSearch(last_code, 634 equal_operator = tokenutil.SearchExcept(token, Type.NON_CODE_TYPES) 635 next_code = tokenutil.SearchExcept(equal_operator, Type.NON_CODE_TYPES) [all...] |