PowerShell type accelerators: PSObject vs PSCustomObject
In PowerShell v3.0 PSCustomObject was introduced. It's like PSObject , but better. Among other improvements (e.g. property order being preserved), creating object from hashtable is simplified: [PSCustomObject]@{one=1; two=2;} Now it seems obvious that this statement: [System.Management.Automation.PSCustomObject]@{one=1; two=2;} would work the same way, because PSCustomObject is an "alias" for full namespace + class name. Instead I get an error: Cannot convert the "System.Collections.Hashtable" value of type "System.Collections.Hashtable" to type "System.Management.Automation.PSCustomObject". I