You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
As discussed with @oehme , it would be neat to improve the current algorithm to detect classes to recompile.
For example, consider these classes:
class A {
private B b
}
class B {
private C c
}
class C {
}
The previous algorithm in ClassSetAnalysis.getRelevantDependents would recompile all classes, if C was changed, because it walks the whole dependency graph and does not consider the "accessibility" of a dependency.
I.e. changing the class C should only recompile C,because it has changed, and B as a user of C and not A, because it is not affected by the change in C.
The updated algorithm does exactly this by checking the "accessibility" (private or not). "Accessible" dependents are recursively evaluated as before, but "private" dependents are not.
The text was updated successfully, but these errors were encountered:
As a follow-up, it could be possible to further enhance the algorithm to not just distinguish between private and non-private, but to also distinguish:
"package private"
protected
However, the current proposal in #10419 is probably a "good enough" improvement for now.
As discussed with @oehme , it would be neat to improve the current algorithm to detect classes to recompile.
For example, consider these classes:
The previous algorithm in
ClassSetAnalysis.getRelevantDependents
would recompile all classes, ifC
was changed, because it walks the whole dependency graph and does not consider the "accessibility" of a dependency.I.e. changing the class
C
should only recompileC
,because it has changed, andB
as a user ofC
and notA
, because it is not affected by the change inC
.The updated algorithm does exactly this by checking the "accessibility" (
private
or not). "Accessible" dependents are recursively evaluated as before, but "private" dependents are not.The text was updated successfully, but these errors were encountered: