Skip to content

Fix '-PipelineVariable' to set variable in the right scope - #16199

Merged
Rob Holt (rjmholt) merged 6 commits into
PowerShell:masterfrom
daxian-dbw:pv
Oct 7, 2021
Merged

Rob Holt (rjmholt) merged 6 commits into
PowerShell:masterfrom
daxian-dbw:pv

Conversation

@daxian-dbw

Copy link
Copy Markdown
Member

PR Summary

Fix #16155

Fix '-PipelineVariable' to set variable in the right scope and to not remove the pipeline variable at the end of pipeline when it's actually using an already existing variable.

PR Checklist

@iSazonov Ilya (iSazonov) left a comment

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.

Have we the same issue for other variables like OutVariable?

@daxian-dbw

Copy link
Copy Markdown
Member Author

No, only pipeline variable is special.

@rjmholt
Rob Holt (rjmholt) merged commit e98a8c8 into PowerShell:master Oct 7, 2021
@rjmholt Rob Holt (rjmholt) added CL-Engine Indicates that a PR should be marked as an engine change in the Change Log CL-General Indicates that a PR should be marked as a general cmdlet change in the Change Log and removed CL-Engine Indicates that a PR should be marked as an engine change in the Change Log labels Oct 7, 2021
@ghost

Copy link
Copy Markdown

🎉v7.3.0-preview.1 has been released which incorporates this pull request.:tada:

Handy links:

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.

PipelineVariable throws error if variable name used exists in function definition

3 participants