Add support for splatting collections that are stored as a property of an object - by Kirk Munro

Status : 


Sign in
to vote
ID 778964 Comments
Status Active Workarounds
Type Suggestion Repros 0
Opened 2/11/2013 7:21:04 AM
Access Restriction Public


PowerShell should allow users to splat collections that are stored in a property of an object.  For example, you can splat PSBoundParameters like this:

Test-Something @PSBoundParameters

You should also be able to splat PSBoundParameters like this:

Test-Something @PSCmdlet.MyInvocation.BoundParameters

This leverages the @ symbol to indicate something is being splatted, but adds support for dereferencing objects in the process.

This feature would make for much simpler splatting logic, especially if implemented at the same time as this request:
Sign in to post a comment.