-
-
Notifications
You must be signed in to change notification settings - Fork 757
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Deprecate BaseRule and state that it will be make sealed - #2365 #2432
Conversation
Codecov Report
@@ Coverage Diff @@
## master #2432 +/- ##
============================================
+ Coverage 82.9% 82.93% +0.03%
- Complexity 2161 2177 +16
============================================
Files 357 359 +2
Lines 6148 6206 +58
Branches 1122 1133 +11
============================================
+ Hits 5097 5147 +50
- Misses 478 480 +2
- Partials 573 579 +6
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should start to clean up old stuff when v2 of detekt is ready.
detekt-api/src/main/kotlin/io/gitlab/arturbosch/detekt/api/BaseRule.kt
Outdated
Show resolved
Hide resolved
@Deprecated(""" | ||
Do not use this class directly. Use Rule or MultiRule instead. | ||
This class was introduced to support a common handling of the rule types mentioned. | ||
This class will be made sealed in a different release and you won't be able to derive from it. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This class will be made sealed in a different release and you won't be able to derive from it. | |
This class will be made sealed in the next release and you won't be able to derive from it. |
Closes #2365 ! |
…eRule.kt Co-Authored-By: M Schalk <30376729+schalkms@users.noreply.github.com>
If you move base rule to an internal package right now you will need to move it outside for 2.0 because all the subclasses of a sealed class should be in the same file. So I think that it's better to keep baserule in the same place with the depreciation. As soon as we make it sealed it will not be able to be extended so the package will not matter. |
@BraisGabin @schalkms true that. However if not using a |
OK, I understand the reason. I'm a bit concern about the binary compatibility but previous changes broke it already so it doesn't matter now. 👍🏻 For me. |
Could you elaborate on what is not binary compatible anymore for 1.7? |
I can be wrong here. I'm not a compatibility expert or nothing near. I think that the |
No description provided.