Skip to content

Use 'is' operator instead of 'as' operator - #13287

Merged
Ilya (iSazonov) merged 4 commits into
PowerShell:masterfrom
xtqqczze:RCS1172
Aug 10, 2020
Merged

Use 'is' operator instead of 'as' operator#13287
Ilya (iSazonov) merged 4 commits into
PowerShell:masterfrom
xtqqczze:RCS1172

Conversation

@xtqqczze

@xtqqczze xtqqczze commented Jul 27, 2020

Copy link
Copy Markdown
Contributor

PR Summary

https://github.com/JosefPihrt/Roslynator/blob/master/docs/analyzers/RCS1172.md

PR Context

PR Checklist

@xtqqczze

xtqqczze commented Jul 27, 2020

Copy link
Copy Markdown
Contributor Author

Ilya (@iSazonov) I am planning work with these analyzers too:

Would you prefer seperate PRs or to add commits here?

GitHub
A collection of 500+ analyzers, refactorings and fixes for C#, powered by Roslyn. - JosefPihrt/Roslynator
GitHub
A collection of 500+ analyzers, refactorings and fixes for C#, powered by Roslyn. - JosefPihrt/Roslynator
GitHub
A collection of 500+ analyzers, refactorings and fixes for C#, powered by Roslyn. - JosefPihrt/Roslynator
GitHub
A collection of 500+ analyzers, refactorings and fixes for C#, powered by Roslyn. - JosefPihrt/Roslynator
GitHub
A collection of 500+ analyzers, refactorings and fixes for C#, powered by Roslyn. - JosefPihrt/Roslynator

@iSazonov

Ilya (iSazonov) commented Jul 27, 2020

Copy link
Copy Markdown
Collaborator

Ilya (@iSazonov) I am planning work with these analyzers too:

I am unlike this. It is not add readability. Please skip.

Good!

I am unlike this. It is not add readability. Please skip.

Good!

Good but we should replace "!(... is ...)" with "is not" on second pass.

Would you prefer seperate PRs or to add commits here?

Please pull new PR for every change - this simplify a code review.

GitHub
A collection of 500+ analyzers, refactorings and fixes for C#, powered by Roslyn. - JosefPihrt/Roslynator
GitHub
A collection of 500+ analyzers, refactorings and fixes for C#, powered by Roslyn. - JosefPihrt/Roslynator
GitHub
A collection of 500+ analyzers, refactorings and fixes for C#, powered by Roslyn. - JosefPihrt/Roslynator
GitHub
A collection of 500+ analyzers, refactorings and fixes for C#, powered by Roslyn. - JosefPihrt/Roslynator
GitHub
A collection of 500+ analyzers, refactorings and fixes for C#, powered by Roslyn. - JosefPihrt/Roslynator

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

I think we can simplify a couple of these a little further, but everything else looks good. Nice work!

@xtqqczze xtqqczze changed the title Autofix RCS1172: Use 'is' operator instead of 'as' operator Use 'is' operator instead of 'as' operator Jul 31, 2020
@iSazonov

Copy link
Copy Markdown
Collaborator

xtqqczze Please rebase to pass CIs.

@iSazonov Ilya (iSazonov) added the CL-CodeCleanup Indicates that a PR should be marked as a Code Cleanup change in the Change Log label Aug 3, 2020
@xtqqczze

xtqqczze commented Aug 9, 2020

Copy link
Copy Markdown
Contributor Author

rebased to restart CI

@iSazonov Ilya (iSazonov) added this to the 7.1.0-preview.6 milestone Aug 10, 2020
@iSazonov
Ilya (iSazonov) merged commit dd85bd1 into PowerShell:master Aug 10, 2020
@xtqqczze
xtqqczze deleted the RCS1172 branch August 10, 2020 14:41
@ghost

Copy link
Copy Markdown

🎉v7.1.0-preview.6 has been released which incorporates this pull request.:tada:

Handy links:

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-CodeCleanup Indicates that a PR should be marked as a Code Cleanup change in the Change Log

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants