Skip to content

Remove ComEnumerator as COM objects using IEnumerator is now supported in .NET 5 - #13259

Merged
Ilya (iSazonov) merged 1 commit into
PowerShell:masterfrom
daxian-dbw:com
Jul 29, 2020
Merged

Ilya (iSazonov) merged 1 commit into
PowerShell:masterfrom
daxian-dbw:com

Conversation

@daxian-dbw

Copy link
Copy Markdown
Member

PR Summary

Fix #12881

.NET 5 now support COM objects using IEnumerator (IEnumVARIANT) (the fix is in .NET 5 preview 7), so in our code, the ComEnumerator, that handles IEnumVARIANT can be removed.

The ComEnumerator was introduced in #4553 3 years ago to make PowerShell able to enumerate COM object.
The support for COM objects that use IEnumerable was back in .NET 3.1, so #11795 reverted some of our changes.
This is a follow-up PR, to remove the remaining ComEnumerator code since now .NET 5 finally supports COM objects that use IEnumerator.

No new test is needed.

PR Checklist

@iSazonov Ilya (iSazonov) added the CL-General Indicates that a PR should be marked as a general cmdlet change in the Change Log label Jul 24, 2020
@daxian-dbw

Copy link
Copy Markdown
Member Author

Ilya (@iSazonov) I think it's ready to merge :) thanks!

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM

@iSazonov
Ilya (iSazonov) merged commit 74ddc3e into PowerShell:master Jul 29, 2020
@iSazonov Ilya (iSazonov) added this to the 7.1.0-preview.7 milestone Jul 29, 2020
@TravisEz13 Travis Plunk (TravisEz13) modified the milestones: 7.1.0-preview.7, 7.1.0-preview.6 Aug 5, 2020
@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-contribs/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-General Indicates that a PR should be marked as a general cmdlet change in the Change Log

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Remove the 'ComEnumerator' code as the support is now in .NET 5

4 participants