void (IElementType elementType, boolean is_module_import, boolean in_parens, final boolean from_future) { SyntaxTreeBuilder builder = myContext.getBuilder(); while (true) { final SyntaxTreeBuilder.Marker asMarker = builder.mark(); if (is_module_import) { // import _ if (!parseDottedNameAsAware(false)) { asMarker.drop(); break; } } else { // from X import _ String token_text = parseIdentifier(getReferenceType()); if (from_future) { // TODO: mark all known future feature names if (TOK_PRINT_FUNCTION.equals(token_text)) { myFutureFlags.add(FutureFeature.PRINT_FUNCTION); } } } if (builder.getTokenType() == PyTokenTypes.AS_KEYWORD) { builder.advanceLexer(); parseIdentifier(PyElementTypes.TARGET_EXPRESSION); } asMarker.done(elementType); if (builder.getTokenType() == PyTokenTypes.COMMA) { builder.advanceLexer(); if (in_parens && builder.getTokenType() == PyTokenTypes.RPAR) { break; } } else { break; } } }