Code analysis reports an error if same subclass consists within two parent classes
I created a subclass called ScopeEnvironment within two different parent classes (StageAccount and StageConditionAccount). If I use the subclass within StageAccount and without prefixing, Illuminated Cloud reports an error despite the fact that there is no error. See screenshot. I used the newest version of illuminated cloud. 2.0.0.5
Workaround was to prefix the subclass e.g. StageAccount.ScopeEnvironment within the parameters.
Comments (6)
-
repo owner -
repo owner - changed status to resolved
Delivered in 2.0.0.6. Please let me know if you continue to see the issue after updating and/or see other issues.
-
reporter Thanks Scott, however the issue isn't fixed. Now the calling class says "Can't resolve symbol" despite the fact that it could be compiled without errors. Furthermore the inner class now produces a warning, that the constructor of the inner class is never used. See attachments.
-
repo owner Okay, I'll take another look. This one was actually more involved than I'd have expected. So just to ensure that I set things up exactly as you have them, is the unresolvable reference in this case (the first screenshot) also inside of the class
StageAccount
? Just trying to get full bearings on what you're showing me. -
reporter No the first one is a separate class called StageAccountBatch. This class uses the class StageAccount and within the class StageAccount there is a subclass ScopeEnvironment.
-
repo owner Okay, so just to be very specific, you have (first image) a class called
StageAccountBatch
which contains the line of code:StageAccount.ScopeEnvironment scopeEnvironment = new StageAccount.ScopeEnvironment(scope);
and then you have (second image) a class named
StageAccount
with an inner class calledScopeEnvironment
. You have a third class namedStageConditionAccount
with an inner class also namedScopeEnvironment
. The reference toStageAccount.ScopeEnvironment
inside ofStageAccountBatch
is yielding the false positive. Is that correct and complete description of the problem? If so, my guess is that it will be quite quick to fix. Thanks for bearing with me on the details, but they're critically important in reproducing, characterizing, and addressing these. - Log in to comment
Thanks, Andreas! I'll see about including the fix in the next build or two. Keep 'em coming as you find them! Just helps to create a tighter seal around the whole thing!