void () { final IElementType tokenType = myDelegate.getTokenType(); if (tokenType == PyTokenTypes.IDENTIFIER || PyTokenTypes.SCALAR_LITERALS.contains(tokenType)) { addOccurrenceInToken(UsageSearchContext.IN_CODE); } else if (PyTokenTypes.STRING_NODES.contains(tokenType)) { scanWordsInToken(UsageSearchContext.IN_STRINGS | UsageSearchContext.IN_FOREIGN_LANGUAGES, false, true); if (tokenType == PyTokenTypes.DOCSTRING) { advanceTodoItemCountsInToken(); } } else if (PyIndexPatternBuilder.COMMENTS.contains(tokenType)) { scanWordsInToken(UsageSearchContext.IN_COMMENTS, false, false); advanceTodoItemCountsInToken(); } else if (!ourSkipWordsScanSet.contains(tokenType)) { scanWordsInToken(UsageSearchContext.IN_PLAIN_TEXT, false, false); } myDelegate.advance(); }