Skip to content

Revert "Change Nullable usage" - #14135

Merged
Ilya (iSazonov) merged 1 commit into
masterfrom
revert-13793-georgettica/change-nullable-usage
Nov 19, 2020
Merged

Revert "Change Nullable usage"#14135
Ilya (iSazonov) merged 1 commit into
masterfrom
revert-13793-georgettica/change-nullable-usage

Conversation

@daxian-dbw

Copy link
Copy Markdown
Member

When the Nullable<T>.HasValue check is necesary, we should keep using Nullable<T>.Value after the check. Comparing to Nullable<T>.GetValueOrDefault(), it's semantically more clear that "I want the current value, not the default value" in this case.

Therefore, revert PR #13793 as agreed in #13791 (comment)

@iSazonov Ilya (iSazonov) added the CL-NotInBuild Indicates that a PR is reverted and not part of the build. label Nov 19, 2020
@iSazonov
Ilya (iSazonov) merged commit 40cbee4 into master Nov 19, 2020
@iSazonov
Ilya (iSazonov) deleted the revert-13793-georgettica/change-nullable-usage branch November 19, 2020 03:15
@iSazonov Ilya (iSazonov) added this to the 7.2.0-preview.2 milestone Nov 19, 2020
Thatgfsj (Thatgfsj) pushed a commit to Thatgfsj/PowerShell that referenced this pull request Aug 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CL-NotInBuild Indicates that a PR is reverted and not part of the build.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants