Skip to content

Conversation

@buyaa-n
Copy link
Contributor

@buyaa-n buyaa-n commented Feb 29, 2024

When updating the Do not compare Span To 'null' analyzer to flag comparisons with 'default'. few more warnings found that this PR is trying to fix. Looks comparisons with default is more intentional than comparing with null, mostly used Unsafe.IsNullRef for fix, wondering if we should suggest the same for the analyzer.

For more context check previous PR: #98958

Learn more form the analyzer proposal

@ghost ghost added the area-Meta label Feb 29, 2024
@ghost ghost assigned buyaa-n Feb 29, 2024
@ghost
Copy link

ghost commented Feb 29, 2024

Tagging subscribers to this area: @dotnet/area-meta
See info in area-owners.md if you want to be subscribed.

Issue Details

When updating the Do not compare Span To 'null' analyzer to flag comparisons with 'default'. few more warnings found that this PR is trying to fix. Looks comparisons with default is more intentional than comparing with null, mostly used Unsafe.IsNullRef for fix

For more context check previous PR: #98958

Learn more form the analyzer proposal

Author: buyaa-n
Assignees: buyaa-n
Labels:

area-Meta

Milestone: -

@buyaa-n buyaa-n requested a review from stephentoub February 29, 2024 21:46
@buyaa-n buyaa-n merged commit fcc0209 into dotnet:main Mar 1, 2024
@buyaa-n buyaa-n deleted the compare-default branch March 1, 2024 04:59
@github-actions github-actions bot locked and limited conversation to collaborators Mar 31, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants