Skip to content
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

Remove KtExpression.isUnitExpression() #7311

Merged
merged 1 commit into from
May 21, 2024

Conversation

3flex
Copy link
Member

@3flex 3flex commented May 19, 2024

This function is a bit overengineered and it's simple to refactor to remove its usage.

@3flex 3flex added this to the 2.0.0 milestone May 19, 2024
@detekt-ci
Copy link
Collaborator

detekt-ci commented May 19, 2024

Warnings
⚠️ It looks like this PR contains functional changes without a corresponding test.

Generated by 🚫 dangerJS against f10ab28

@3flex 3flex added the breaking change Marker for breaking changes which should be highlighted in the changelog label May 19, 2024
Copy link

codecov bot commented May 19, 2024

Codecov Report

Attention: Patch coverage is 0% with 2 lines in your changes are missing coverage. Please review.

Project coverage is 84.78%. Comparing base (6864037) to head (f10ab28).

Files Patch % Lines
...rbosch/detekt/rules/bugs/ImplicitUnitReturnType.kt 0.00% 0 Missing and 1 partial ⚠️
...tekt/libraries/LibraryCodeMustSpecifyReturnType.kt 0.00% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff            @@
##               main    #7311   +/-   ##
=========================================
  Coverage     84.78%   84.78%           
  Complexity     3993     3993           
=========================================
  Files           576      575    -1     
  Lines         12021    12015    -6     
  Branches       2478     2476    -2     
=========================================
- Hits          10192    10187    -5     
  Misses          598      598           
+ Partials       1231     1230    -1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Member

@BraisGabin BraisGabin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

StandardNames.FqNames.unit.shortName().asString() was so overkill for just "Unit"! 🤣

Copy link
Member

@schalkms schalkms left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed

@3flex 3flex force-pushed the KtExpression.isUnitExpression branch from 505224d to f10ab28 Compare May 21, 2024 03:13
@3flex 3flex enabled auto-merge (squash) May 21, 2024 03:13
@3flex 3flex merged commit 1a98530 into detekt:main May 21, 2024
20 of 21 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api breaking change Marker for breaking changes which should be highlighted in the changelog rules
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants