Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

ReturnArray.Empty instead of collection[]#25137

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Conversation

@ArmaanMcleod
Copy link
Contributor

@ArmaanMcleodArmaanMcleod commentedMar 7, 2025
edited
Loading

PR Summary

ReturnArray.Empty instead of collection[].

Missed this in#25126 (comment)

PR Context

PR Checklist

@ArmaanMcleod
Copy link
ContributorAuthor

@iSazonov do you have issues with VSCode and editorconfig not using rules? I still get recommendation to use[] for this code.

@iSazonov
Copy link
Collaborator

iSazonov commentedMar 7, 2025
edited by unfurl-linksbot
Loading

@ArmaanMcleod I played with the option, and it works for me in VS Code. Maybe you need restart? Or not
https://learn.microsoft.com/en-us/dotnet/fundamentals/code-analysis/style-rules/ide0301 rule but the
https://learn.microsoft.com/en-us/dotnet/fundamentals/code-analysis/style-rules/ide0300 rule works for you?

Learn about code analysis rule IDE0301: Use collection expression for empty
Learn about code analysis rule IDE0300: Use collection expression
ArmaanMcleod reacted with thumbs up emoji

@ArmaanMcleodArmaanMcleod changed the titleReturnEnumerable.Empty instead of collection[]ReturnArray.Empty instead of collection[]Mar 7, 2025
@ArmaanMcleod
Copy link
ContributorAuthor

ArmaanMcleod commentedMar 7, 2025
edited by unfurl-linksbot
Loading

@ArmaanMcleod I played with the option, and it works for me in VS Code. Maybe you need restart? Or nothttps://learn.microsoft.com/en-us/dotnet/fundamentals/code-analysis/style-rules/ide0301 rule but thehttps://learn.microsoft.com/en-us/dotnet/fundamentals/code-analysis/style-rules/ide0300 rule works for you?

**IDE0301: Use collection expression for empty - .NET**Learn about code analysis rule IDE0301: Use collection expression for empty

**IDE0300: Use collection expression for array - .NET**Learn about code analysis rule IDE0300: Use collection expression

Thanks@iSazonov. I will play around with it, maybe need to reinstall extension.

Learn about code analysis rule IDE0301: Use collection expression for empty
Learn about code analysis rule IDE0300: Use collection expression

@iSazonov

This comment was marked as outdated.

@azure-pipelines

This comment was marked as outdated.

@iSazonoviSazonov added the CL-CodeCleanupIndicates that a PR should be marked as a Code Cleanup change in the Change Log labelMar 7, 2025
@iSazonoviSazonov self-assigned thisMar 7, 2025
@iSazonoviSazonov merged commit210ca83 intoPowerShell:masterMar 7, 2025
39 of 41 checks passed
@microsoft-github-policy-service
Copy link
Contributor

microsoft-github-policy-servicebot commentedMar 7, 2025
edited by unfurl-linksbot
Loading

📣 Hey@ArmaanMcleod, how did we do? We would love to hear your feedback with the link below! 🗣️

🔗https://aka.ms/PSRepoFeedback

Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

@iSazonoviSazonoviSazonov approved these changes

Assignees

@iSazonoviSazonov

Labels

CL-CodeCleanupIndicates that a PR should be marked as a Code Cleanup change in the Change Log

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

2 participants

@ArmaanMcleod@iSazonov

[8]ページ先頭

©2009-2025 Movatter.jp