Is it expected (no pun intended) that when running...
# ksp
e
Is it expected (no pun intended) that when running KSP on a non common compilation that has a class with an
actual
modifier, that
KsClassDeclaration.isActual
will return
false
?
j
no, if the class is declared in source of the build unit, KSP only checks for keywords (
actual
) on the declaration to determine if it is actual.
e
So if there is an
actual
keyword, KSP should return
true
?
j
yes
e
OK I'll play around a little more just to make sure I'm not doing something wrong, and then I'll file an issue
j
you can post here before filing an issue so I can take a look to see if there is other reason for the mismatch.
e
There is a level of indirection in the code so it's hard to post it, but the gist is that I'm getting a
KSValueParameter
from a
KSFunctionDeclaration.parameters
and then calling
(type.declaration as KSClassDeclaration).isActual
j
I see, is the
type.declaration
a declaration in the source or library?
e
It's in a library. However if I get the
KSClassDeclaration
of
type.declaration
directly using an annotation, then
isActual
is
true
even though the declaration is still from a library.
j
I see, please file an issue for further investigation.
e
False alarm, KSP was running for the library as well, and that was what was seeing
isActual
as
true
.
👍 1