@@ -55,45 +55,6 @@ class KSValueArgumentImpl private constructor(
55
55
override fun toString (): String {
56
56
return " ${name?.asString() ? : " " } :$value "
57
57
}
58
- //
59
- // private fun KtAnnotationValue.toValue(): Any? = when (this) {
60
- // is KtArrayAnnotationValue -> this.values.map { it.toValue() }
61
- // is KtAnnotationApplicationValue -> KSAnnotationImpl.getCached(this.annotationValue)
62
- // // TODO: Enum entry should return a type, use declaration as a placeholder.
63
- // is KtEnumEntryAnnotationValue -> this.callableId?.classId?.let {
64
- // analyze {
65
- // it.toKtClassSymbol()?.let {
66
- // it.declarations().filterIsInstance<KSClassDeclarationEnumEntryImpl>().singleOrNull {
67
- // it.simpleName.asString() == [email protected] ?.callableName?.asString()
68
- // }
69
- // }
70
- // }
71
- // } ?: KSErrorType(callableId?.toString())
72
- // is KtKClassAnnotationValue -> {
73
- // val classDeclaration = when (this) {
74
- // is KtKClassAnnotationValue.KtNonLocalKClassAnnotationValue -> analyze {
75
- // ([email protected] ())?.let { KSClassDeclarationImpl.getCached(it) }
76
- // }
77
- // is KtKClassAnnotationValue.KtLocalKClassAnnotationValue -> analyze {
78
-
79
- // KSClassDeclarationImpl.getCached(it)
80
- // }
81
- // }
82
- // is KtKClassAnnotationValue.KtErrorClassAnnotationValue -> null
83
- // }
84
- // classDeclaration?.asStarProjectedType() ?: KSErrorType(
85
- // when (this) {
86
- // is KtKClassAnnotationValue.KtErrorClassAnnotationValue -> unresolvedQualifierName
87
- // is KtKClassAnnotationValue.KtLocalKClassAnnotationValue -> ktClass.run {
88
- // fqName?.asString() ?: name
89
- // }
90
- // is KtKClassAnnotationValue.KtNonLocalKClassAnnotationValue -> classId.asFqNameString()
91
- // } ?: sourcePsi?.text
92
- // )
93
- // }
94
- // is KtConstantAnnotationValue -> this.constantValue.value
95
- // is KtUnsupportedAnnotationValue -> null
96
- // }
97
58
98
59
override fun defer (): Restorable = Restorable { getCached(namedAnnotationValue, origin) }
99
60
}
0 commit comments