-
-
Notifications
You must be signed in to change notification settings - Fork 3.7k
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
FinalClassCheck: 'extractQualifiedName' omits 2nd ident of package name #5706
Comments
@romani Don't we have |
I am ok to re-use FullIdent, but one day it will not be API :) class. |
I'm not sure what you mean, API versus util doesn't matter for checks. |
src/main/java/com/puppycrawl/tools/checkstyle/api/FullIdent.java Check is ok to reuse this class at any package. |
yes, I know you meant the API package. |
If you are referring to my custom check, anyone outside checkstyle can use utils if that is where you plan to move |
it was just side note(off topic) for future of FullIdent class. |
Fix was merged |
checkstyle/src/main/java/com/puppycrawl/tools/checkstyle/checks/design/FinalClassCheck.java
Line 95 in 90f20e0
When debugging tests like
testFinalClass
,extractQualifiedName
returnscom.tools.checkstyle.checks.design.finalclass
when the package is clearly defined ascom.puppycrawl.tools.checkstyle.checks.design.finalclass
(puppycrawl
is missing).Looking at the code, when it gets to the top node of the package name, it only pulls in the first
IDENT
and not them both.I am not sure if this bug presents itself in the CLI somehow as I am not that familiar with the check.
I found this bug by duplicating the same code in my own custom check.
The text was updated successfully, but these errors were encountered: