- 
                Notifications
    
You must be signed in to change notification settings  - Fork 403
 
Open
Description
Summary of the new feature
Would be nice is PSSA could add a rule that makes sure variables are strongly typed.
Should be an optional rule, disabled by default, to not break with PowerShell default behavior. But for projects where you want high code quality, readability, and the added safety that explicit types can add, it'd be nice with a lint rule to enforce it.
I'm looking into learning Python, and got inspired by tools like:
- mypy: https://mypy-lang.org/, https://github.com/python/mypy
 - pylyzer: https://github.com/mtshiba/pylyzer
 - ty by Astral: https://docs.astral.sh/ty/, https://github.com/astral-sh/ty, https://github.com/astral-sh/ty-vscode
 
Proposed technical implementation details (optional)
- Error or warn when no type is used, or generic types like 
[object],[array]and[int]. - Require explicit data types.
 
What is the latest version of PSScriptAnalyzer at the point of writing
Metadata
Metadata
Assignees
Labels
No labels