In FIR, how do you search all items accessible in ...
# compiler
c
In FIR, how do you search all items accessible in your current scope? I'm specifically looking for extension properties that have been imported.
I think I might have found it:
FirClass.unsubstitutedScope().processAllProperties
. But I can't figure out how to find the
FirClass
that declared an extension member, considering they're usually declared at the top level, but the scope provider requires one. Does anyone know how I'd do that? There's
FirBasedSymbol#getContainingSymbol
, but I can't get the scope from an
FirFile
.
d
There is no API for getting all extension functions/properties. You can get them only by specific names using
symbolProvider
.