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

CastNullableToNonNullableType - Check the SimpleType instead of typeElement #6071

Merged
merged 1 commit into from
May 3, 2023

Conversation

atulgpt
Copy link
Contributor

@atulgpt atulgpt commented May 3, 2023

Fixes: #6070

@detekt-ci detekt-ci added the rules label May 3, 2023
@atulgpt atulgpt force-pushed the fixes/false-positive-cast-nullable branch from 8688205 to 3924e8f Compare May 3, 2023 20:59
@codecov
Copy link

codecov bot commented May 3, 2023

Codecov Report

Merging #6071 (3924e8f) into main (d3d260c) will decrease coverage by 0.01%.
The diff coverage is 50.00%.

@@             Coverage Diff              @@
##               main    #6071      +/-   ##
============================================
- Coverage     84.86%   84.86%   -0.01%     
  Complexity     3977     3977              
============================================
  Files           564      564              
  Lines         13304    13305       +1     
  Branches       2327     2328       +1     
============================================
  Hits          11291    11291              
  Misses          870      870              
- Partials       1143     1144       +1     
Impacted Files Coverage Δ
...detekt/rules/bugs/CastNullableToNonNullableType.kt 88.46% <50.00%> (-3.54%) ⬇️

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.

Thanks for the fast fix!

@BraisGabin BraisGabin added this to the 1.23.0 milestone May 3, 2023
@BraisGabin BraisGabin merged commit 6734152 into detekt:main May 3, 2023
@cortinico cortinico changed the title Check the SimpleType instead of typeElement CastNullableToNonNullableType - Check the SimpleType instead of typeElement May 3, 2023
@atulgpt atulgpt deleted the fixes/false-positive-cast-nullable branch May 4, 2023 05:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

CastNullableToNonNullableType: false positive on possibly nullable type parameters
3 participants