void (@NotNull PyStringLiteralExpression element, @NotNull TokenConsumer consumer) { String stringValue = element.getStringValue(); List<PyStringFormatParser.FormatStringChunk> chunks = PyStringFormatParser.parsePercentFormat(stringValue); Splitter splitter = PlainTextSplitter.getInstance(); for (PyStringFormatParser.FormatStringChunk chunk : chunks) { if (chunk instanceof PyStringFormatParser.ConstantChunk) { int startIndex = element.valueOffsetToTextOffset(chunk.getStartIndex()); int endIndex = element.valueOffsetToTextOffset(chunk.getEndIndex()); String text = element.getText().substring(startIndex, endIndex); consumer.consumeToken(element, text, false, startIndex, TextRange.allOf(text), splitter); } } }