Skip to content
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

When generating OutputType don't cast to Type[] #21605

Conversation

SeeminglyScience
Copy link
Collaborator

This fixes an issue with constrained language mode where modules that specify multiple OutputType's as System.Type would throw due to Type[] not being a "core type".

An example of a command shipped with Windows that would previously throw is Get-DeliveryOptimizationStatus from the DeliveryOptimization module.

PR Summary

PR Context

PR Checklist

This fixes an issue with constrained language mode where modules that
specify multiple `OutputType`'s as `System.Type` would throw due to
`Type[]` not being a "core type".
@SeeminglyScience SeeminglyScience changed the title When generating OutputType don't cast to Type[] When generating OutputType don't cast to Type[] May 3, 2024
@TravisEz13 TravisEz13 added the CL-Engine Indicates that a PR should be marked as an engine change in the Change Log label May 6, 2024
@TravisEz13 TravisEz13 self-assigned this May 6, 2024
Copy link
Member

@daxian-dbw daxian-dbw left a comment

Choose a reason for hiding this comment

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

LGTM

@daxian-dbw daxian-dbw merged commit 467538f into PowerShell:master May 6, 2024
37 checks passed
Copy link
Contributor

microsoft-github-policy-service bot commented May 6, 2024

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

🔗 https://aka.ms/PSRepoFeedback

@TravisEz13 TravisEz13 added the Backport-5.1-Consider Consider to backport to Windows PowerShell 5.1 due to impact label May 6, 2024
@SeeminglyScience SeeminglyScience deleted the fix-mixed-language-output-type branch May 6, 2024 19:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Backport-5.1-Consider Consider to backport to Windows PowerShell 5.1 due to impact Backport-7.2.x-Consider BackPort-7.4.x-Consider CL-Engine Indicates that a PR should be marked as an engine change in the Change Log
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants