GitOrigin-RevId: e425557b4909dd24b4df8e78ce67ebfaf7eb063d
This commit is contained in:
Alexey Kudravtsev
2024-03-20 13:15:33 +01:00
committed by intellij-monorepo-bot
parent 432230eb34
commit 4458ed6efc
2 changed files with 2 additions and 2 deletions

View File

@@ -74,7 +74,7 @@ public final class AnnotationSessionImpl extends AnnotationSession {
static <T> T computeWithSession(boolean batchMode,
@NotNull Object annotator,
@NotNull AnnotationSessionImpl session,
@NotNull AnnotationSession session,
@NotNull Function<? super AnnotationHolderImpl, T> runnable) {
AnnotationHolderImpl holder = new AnnotationHolderImpl(annotator, session, batchMode);
return runnable.apply(holder);

View File

@@ -131,7 +131,7 @@ final class AnnotatorRunner {
return;
}
// create AnnotationHolderImpl for each Annotator to make it immutable thread-safe converter to the corresponding HighlightInfo
AnnotationSessionImpl.computeWithSession(myBatchMode, annotator, (AnnotationSessionImpl)myHighlightInfoHolder.getAnnotationSession(), annotationHolder -> {
AnnotationSessionImpl.computeWithSession(myBatchMode, annotator, myHighlightInfoHolder.getAnnotationSession(), annotationHolder -> {
HighlightersRecycler emptyElementRecycler = new HighlightersRecycler(); // no need to call incinerate/release because it's always empty
for (PsiElement element : insideThenOutside) {
if (!supported.contains(element.getLanguage())) {