Brady Aiello
03/08/2021, 8:10 PMAllOpenVisibilityTransformer
is a DeclarationAttributeAltererExtension
. But it looks like All Open only works because DeclarationAttributeAltererExtension
is registered in KotlinCoreEnvironment. I'm wondering if there's a way for a user to register a plugin extension point, or if it's gotta go into KotlinCoreEnvironment
, meaning making changes to the compiler itself? For the latter, I'd just want to add a few more methods to DeclarationAttributeAltererExtension
so it could do more than change modality, specifically, changing visibility through a compiler plugin.dmitriy.novozhilov
03/08/2021, 9:06 PMAllOpenVisibilityTransformer
is a very early prototype made as proof of concept of extension API of FIR. That prototype showed to us some disadvantages of that API (in part of creating new declarations), so we gonna to change it (but only after FIR came to alpha stage). Also there are multiple of unresolved problems, like how to plugin developer should generate bodies of declarations, created by plugin (on FIR stage, on IR, something else)
So actually there is no legal way to register FIR plugin, but when it will be done in some state we will announce it, so compiler plugin devs can give us feedback (because we really want to create good compiler API, which won't be similar to existed dirty one)dmitriy.novozhilov
03/08/2021, 9:07 PMAllOpenVisibilityTransformer
(I can give more detailed instructions, if you want)