You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[System.Diagnostics.CodeAnalysis.SuppressMessage("Design","CA1031:Do not catch general exception types",Justification="Uses ThrowTerminatingError() instead")]
218
+
[System.Diagnostics.CodeAnalysis.SuppressMessage("Usage","VSTHRD002:Avoid problematic synchronous waits",Justification="We have to wait here, it's the whole program.")]
[System.Diagnostics.CodeAnalysis.SuppressMessage("Performance","CA1825:Avoid zero-length array allocations",Justification="Cannot use Array.Empty, since it must work in net452")]
385
386
privatestaticVersionGetPSVersion()
386
387
{
387
388
// In order to read the $PSVersionTable variable,
388
389
// we are forced to create a new runspace to avoid concurrency issues,
389
390
// which is expensive.
390
391
// Rather than do that, we instead go straight to the source,
391
392
// which is a static property, internal in WinPS and public in PS 6+
[System.Diagnostics.CodeAnalysis.SuppressMessage("Usage","VSTHRD002:Avoid problematic synchronous waits",Justification="This is a legacy implementation.")]
0 commit comments