@Override
  protected ASTNode doParseContents(@NotNull ASTNode chameleon, @NotNull PsiElement outerPsi) {
    PsiElement psi = chameleon.getPsi();
    Project project = psi.getProject();
    Language languageForParser = getLanguageForParser(psi);
    RegExpParserDefinition definition = (RegExpParserDefinition)LanguageParserDefinitions.INSTANCE.forLanguage(languageForParser);
    EnumSet<RegExpCapability> capabilities = setupCapabilities(psi, EnumSet.copyOf(definition.getDefaultCapabilities()));
    RegExpLexer lexer = definition.createLexer(project, capabilities);
    PsiParser parser = definition.createParser(project, capabilities);
    PsiBuilder builder = PsiBuilderFactory.getInstance().createBuilder(project, chameleon, lexer, languageForParser, chameleon.getChars());
    var startTime = System.nanoTime();
    ((LightPsiParser)parser).parseLight(this, builder);
    var result = builder.getTreeBuilt().getFirstChildNode();
    ParsingDiagnostics.registerParse(builder, getLanguage(), System.nanoTime() - startTime);
    return result;
  }
@Override
  protected ASTNode doParseContents(@NotNull ASTNode chameleon, @NotNull PsiElement outerPsi)