title: PowerShell: The difference in parentheses expressions
body: <p>I've been experimenting with the different forms of operators/expressions involving parentheses, but I can't find an explanation for an interaction I'm running into.  Namely, <code>( )</code> and <code>$( )</code> (subexpression operator) are not equivalents.  Nor is it equivalent to <code>@( )</code> (array operator).  For most cases this doesn't matter, but when trying to evaluate the contents of the parentheses as an expression (for example, variable assignment), they're different.  I'm looking for an answer on <em>what</em> parentheses are doing when they aren't explicitly one operator or another and the <code>about_</code> documents don't call this out.</p>
  
  <hr>
  
  <pre><code>($var = Test-Something) # -&gt; this passes through
  $($var = Test-Something) # -&gt; $null
  @($var = Test-Something) # -&gt; $null
  </code></pre>
  
  <hr>
  
  <p><em><a href="https://docs.microsoft.com/en-us/powershell/module/microsoft.powershell.core/about/about_operators?view=powershell-5.1" rel="nofollow noreferrer">about_Operators</a></em></p>