From e7eaf08cd7e7dae7c5a539405f60fba94541b3c9 Mon Sep 17 00:00:00 2001 From: Dmitrii Gridin Date: Wed, 25 Jan 2023 14:34:10 +0100 Subject: [PATCH] [SLC] introduce EmptyAnnotationsProvider ^KT-56046 --- .../annotations/EmptyAnnotationsProvider.kt | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 analysis/symbol-light-classes/src/org/jetbrains/kotlin/light/classes/symbol/annotations/EmptyAnnotationsProvider.kt diff --git a/analysis/symbol-light-classes/src/org/jetbrains/kotlin/light/classes/symbol/annotations/EmptyAnnotationsProvider.kt b/analysis/symbol-light-classes/src/org/jetbrains/kotlin/light/classes/symbol/annotations/EmptyAnnotationsProvider.kt new file mode 100644 index 00000000000..0537a4a0a4a --- /dev/null +++ b/analysis/symbol-light-classes/src/org/jetbrains/kotlin/light/classes/symbol/annotations/EmptyAnnotationsProvider.kt @@ -0,0 +1,17 @@ +/* + * Copyright 2010-2023 JetBrains s.r.o. and Kotlin Programming Language contributors. + * Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file. + */ + +package org.jetbrains.kotlin.light.classes.symbol.annotations + +import org.jetbrains.kotlin.analysis.api.annotations.KtAnnotationApplication +import org.jetbrains.kotlin.name.ClassId + +object EmptyAnnotationsProvider : AnnotationsProvider { + override fun classIds(): Collection = emptyList() + override fun get(classId: ClassId): Collection = emptyList() + override fun contains(classId: ClassId): Boolean = false + override fun isTheSameAs(other: Any?): Boolean = this === other + override fun ownerClassId(): ClassId? = null +}