Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
class IntSummableProcessor(
private val options: Map<String, String>,
private val codeGenerator: CodeGenerator,
private val logger: KSPLogger
) : SymbolProcessor {
private lateinit var intType: KSType
override fun process(resolver: Resolver): List<KSAnnotated> {
intType = resolver.builtIns.intType
val symbols = resolver.getSymbolsWithAnnotation(IntSummable::class.qualifiedName!!)
val unableToProcess = symbols.filterNot { it.validate() }
symbols.filter { it is KSClassDeclaration && it.validate() }
.forEach { it.accept(Visitor(), Unit) }
return unableToProcess.toList()
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment