◐ Shell
clean mode source ↗

Remove Conditional Compilation and Runtime Checks for v3 or v4 by liamjpeters · Pull Request #2150 · PowerShell/PSScriptAnalyzer

PR Summary

The minimum PS version the module can be loaded in is 5.1 (since e849068).

All of the conditional compilation checks around PSV3 and PSV4 can be removed/simplified.

Similarly the runtime checks for anything less than major version 5 can be simplified.

There are probably still some functions acting as compat shims to bridge functionality missing in 3 or 4 which could also be replaced.

PR Checklist