René's URL Explorer Experiment


Title: Add AvoidReservedWordsAsFunctionNames Rule by liamjpeters · Pull Request #2128 · PowerShell/PSScriptAnalyzer · GitHub

Open Graph Title: Add AvoidReservedWordsAsFunctionNames Rule by liamjpeters · Pull Request #2128 · PowerShell/PSScriptAnalyzer

X Title: Add AvoidReservedWordsAsFunctionNames Rule by liamjpeters · Pull Request #2128 · PowerShell/PSScriptAnalyzer

Description: PR Summary Adds a new rule that warns when reserved words are used as function names. function function {} function if { function else {} } function global:try {} function private:catch {} Fixes #2099 I wrote a blog post about putting this together 😀 PR Checklist PR has a meaningful title Use the present tense and imperative mood when describing your changes Summarized changes Change is not breaking Make sure all .cs, .ps1 and .psm1 files have the correct copyright header Make sure you've added a new test if existing tests do not effectively test the code changed and/or updated documentation This PR is ready to merge and is not Work in Progress. If the PR is work in progress, please add the prefix WIP: to the beginning of the title and remove the prefix when the PR is ready.

Open Graph Description: PR Summary Adds a new rule that warns when reserved words are used as function names. function function {} function if { function else {} } function global:try {} function private:catch {} F...

X Description: PR Summary Adds a new rule that warns when reserved words are used as function names. function function {} function if { function else {} } function global:try {} function private:catch {} F...

Opengraph URL: https://github.com/PowerShell/PSScriptAnalyzer/pull/2128

X: @github

direct link

Domain: github.com

react-profiling0
react-import-mapreact,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322
route-pattern/:user_id/:repository/pull/:id/files(.:format)
route-controllerpull_requests
route-actionfiles
fetch-noncev2:eed370b1-09e4-bfd2-fa4b-0c5dfcf4f539
current-catalog-service-hashae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b
request-idD11E:213959:93688:C3E8B:6AFD0C14
html-safe-nonce4276fbbee66d57e3a665c52346beb4e6acb8f7b7b80983fbd3af9efb4d442839
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJEMTFFOjIxMzk1OTo5MzY4ODpDM0U4Qjo2QUZEMEMxNCIsInZpc2l0b3JfaWQiOiIzMzYxODAxNTc4NzU0MTQ5Mzk2IiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0=
visitor-hmac58db2c909b4abf2e4d5d62259d3fa18fe6096c16a1cf4f599c55bfa830c2ea83
hovercard-subject-tagpull_request:2790534486
github-keyboard-shortcutsrepository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///pull_requests/show/files
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files
twitter:imagehttps://avatars.githubusercontent.com/u/6566675?s=400&v=4
twitter:cardsummary_large_image
og:imagehttps://avatars.githubusercontent.com/u/6566675?s=400&v=4
og:image:altPR Summary Adds a new rule that warns when reserved words are used as function names. function function {} function if { function else {} } function global:try {} function private:catch {} F...
og:site_nameGitHub
og:typeobject
hostnamegithub.com
expected-hostnamegithub.com
Noneb29de2abb97b6307b16270785efeb58b51a117d5a9b659acf00b77aa00e7043b
turbo-cache-controlno-preview
diff-viewunified
go-importgithub.com/PowerShell/PSScriptAnalyzer git https://github.com/PowerShell/PSScriptAnalyzer.git
octolytics-dimension-user_id11524380
octolytics-dimension-user_loginPowerShell
octolytics-dimension-repository_id33149177
octolytics-dimension-repository_nwoPowerShell/PSScriptAnalyzer
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id33149177
octolytics-dimension-repository_network_root_nwoPowerShell/PSScriptAnalyzer
turbo-body-classeslogged-out env-production page-responsive full-width
disable-turbotrue
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release8c9e619def6d670dc18a45d3b02cea938c1c7e47
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files#start-of-content
https://github.com/
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2FPowerShell%2FPSScriptAnalyzer%2Fpull%2F2128%2Ffiles
GitHubRepository hosting, code review, and collaborationhttps://github.com/platform
CopilotAI coding agent for tasks, projects, and automated workhttps://github.com/features/copilot
ActionsCI/CD and automationhttps://github.com/features/actions
Code QualityQuality analysis, fixes, and enforcementhttps://github.com/features/code-quality
CodespacesCloud development environmentshttps://github.com/features/codespaces
Code SecurityVulnerability detection and remediationhttps://github.com/security/advanced-security/code-security
Secret ProtectionSecret scanning and leak preventionhttps://github.com/security/advanced-security/secret-protection
All Featureshttps://github.com/features
Documentationhttps://docs.github.com/en
Traininghttps://learn.github.com/skills
Certificationshttps://learn.github.com/credentials
Build with Copilothttps://github.com/features/ai
Customize Copilothttps://docs.github.com/en/copilot/how-tos/copilot-on-github/customize-copilot/customize-copilot-overview
Integrationshttps://github.com/marketplace
Trending reposhttps://github.com/trending
GitHub Sponsorshttps://github.com/open-source/sponsors
Developer articleshttps://github.com/resources/articles
ChangelogYour source for the latest features, improvements, and fixes across GitHub products, all in one place.https://github.blog/changelog/
Enterpriseshttps://github.com/enterprise
Teamhttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
See all industrieshttps://github.com/solutions/industry
Why GitHubhttps://github.com/why-github
Customer Storieshttps://github.com/customer-stories
Business insightshttps://github.com/solutions/executive-insights
Trust Centerhttps://github.com/trust-center
GitHub Advanced SecurityEnterprise-grade code securityhttps://github.com/security/advanced-security
Copilot for businessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Documentationhttps://docs.github.com/en
Resource centerhttps://github.com/resources
Bloghttps://github.blog/
Events & webinarshttps://github.com/resources/events
Community Forumhttps://github.com/orgs/community/discussions
Customer Storieshttps://github.com/customer-stories
Integrationshttps://github.com/marketplace
Customer supporthttps://help.github.com/
Traininghttps://learn.github.com/skills
GitHub Statushttps://www.githubstatus.com/
Abouthttps://github.com/about
Partnershttps://github.com/partners
Changeloghttps://github.blog/changelog/
GitHub UniverseThe event for developers, by developers — talks, workshops, and what’s next for GitHub.https://githubuniverse.com/
Pricinghttps://github.com/pricing
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2FPowerShell%2FPSScriptAnalyzer%2Fpull%2F2128%2Ffiles
Sign uphttps://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fpull_requests%2Fshow%2Ffiles&source=header-repo&source_repo=PowerShell%2FPSScriptAnalyzer
Reloadhttps://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files
Reloadhttps://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files
Reloadhttps://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files
PowerShellhttps://github.com/PowerShell
PSScriptAnalyzerhttps://github.com/PowerShell/PSScriptAnalyzer
Codehttps://github.com/PowerShell/PSScriptAnalyzer
Issues407 (407)https://github.com/PowerShell/PSScriptAnalyzer/issues
Pull requests34 (34)https://github.com/PowerShell/PSScriptAnalyzer/pulls
Discussionshttps://github.com/PowerShell/PSScriptAnalyzer/discussions
Actionshttps://github.com/PowerShell/PSScriptAnalyzer/actions
Projectshttps://github.com/PowerShell/PSScriptAnalyzer/projects
Wikihttps://github.com/PowerShell/PSScriptAnalyzer/wiki
Security and qualityhttps://github.com/PowerShell/PSScriptAnalyzer/security
Insightshttps://github.com/PowerShell/PSScriptAnalyzer/insights
Sign up for GitHub https://github.com/signup?return_to=%2FPowerShell%2FPSScriptAnalyzer%2Fissues%2Fnew%2Fchoose
terms of servicehttps://docs.github.com/terms
privacy statementhttps://docs.github.com/privacy
Sign inhttps://github.com/login?return_to=%2FPowerShell%2FPSScriptAnalyzer%2Fissues%2Fnew%2Fchoose
Andy Jordan (andyleejordan)https://github.com/andyleejordan
PowerShell:mainhttps://github.com/PowerShell/PSScriptAnalyzer/tree/main
liamjpeters:#2099PSAvoidReservedWordsAsFunctionNameshttps://github.com/liamjpeters/PSScriptAnalyzer/tree/%232099PSAvoidReservedWordsAsFunctionNames
Conversation 20 https://github.com/PowerShell/PSScriptAnalyzer/pull/2128
Commits 9 https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/commits
Checks 0 https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/checks
Files changed https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files
Please reload this pagehttps://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files
Add AvoidReservedWordsAsFunctionNames Rule https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files#top
Show all changes 9 commits https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files
fbe1489 fix: Update helper GetScriptExtentForFunctionName to return correct e… liamjpeters Sep 1, 2025 https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/commits/fbe1489d76261903d6202f356ac927fa178d8165
b4f67c2 Add AvoidReservedWordsAsFunctionNames rule liamjpeters Sep 1, 2025 https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/commits/b4f67c2c4c6bf8d896557ccca47fa614a9374466
1819eb3 fix: Handle functions with scopes liamjpeters Sep 1, 2025 https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/commits/1819eb334f7380020790403e1798dabbed38e634
1e5c1b2 Copyright header liamjpeters Sep 3, 2025 https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/commits/1e5c1b2b15163725a0fe63a9a4cab67d496d78b8
3b56a76 Extend Substring tests to starts with reserved word, ends with reserv… liamjpeters Oct 16, 2025 https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/commits/3b56a765bb8d7528720df7d46c30df1d6f9ec637
4510ff4 Check if the function name is 'Function' case insensitively. Add a te… liamjpeters Oct 16, 2025 https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/commits/4510ff4c05abbc7a354f6a475a3f63d2aece0e29
a9e6182 Fix casing of common name liamjpeters Oct 16, 2025 https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/commits/a9e61823c7a791cbc61d7496a414b213486a9ce3
80172fe AvoidReservedWordsAsFunctionNames: factor our function name for reada… liamjpeters Oct 21, 2025 https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/commits/80172fedf6aef52312afe9c37333db3a5ac3d2c8
8f89a1b Remove reserved words which do not pose an issue: liamjpeters Oct 21, 2025 https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/commits/8f89a1b964ac364ce63a76404bf74f47f7380a8f
Clear filters https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files
Please reload this pagehttps://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files
Please reload this pagehttps://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files
Helper.cs https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files#diff-427edd792ddc5404af08d95e98ffdd68d3d282caa731e104ee2c1a1998c506b9
AvoidReservedWordsAsFunctionNames.cs https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files#diff-3062a08f84e3b8cb080580ae1909c029657e017654b93235332b7221e4416934
Strings.resx https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files#diff-dcff94e6a5c5ee1dc9226dea0752aba08f8f1f53020b4a0e67f1ac944036b8c3
GetScriptAnalyzerRule.tests.ps1 https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files#diff-2999e95c336a14ae8a92b0c336e6709d25ccba6062c55462f0b9cc6d2f87ed68
AvoidReservedWordsAsFunctionNames.tests.ps1 https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files#diff-3fa22d63fb060b1e31ea282cabc650c885e8d18169705e51122269c28d84c784
AvoidReservedWordsAsFunctionNames.md https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files#diff-e16968604856cde0429cf6750d2a1e5ce5019d48ab1771dd249767a64b0cacaa
README.md https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files#diff-aa3ee3522a3ec73c6f36f2fe020f02ee8517299d57cfe67d99ff0efd2038a0d5
https://github.com/PowerShell/PSScriptAnalyzer/blob/main/.github/CODEOWNERS#L2
Engine/Helper.cshttps://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files#diff-427edd792ddc5404af08d95e98ffdd68d3d282caa731e104ee2c1a1998c506b9
View file https://github.com/liamjpeters/PSScriptAnalyzer/blob/8f89a1b964ac364ce63a76404bf74f47f7380a8f/Engine/Helper.cs
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/{{ revealButtonHref }}
https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files#diff-427edd792ddc5404af08d95e98ffdd68d3d282caa731e104ee2c1a1998c506b9
https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files#diff-427edd792ddc5404af08d95e98ffdd68d3d282caa731e104ee2c1a1998c506b9
https://github.com/PowerShell/PSScriptAnalyzer/blob/main/.github/CODEOWNERS#L2
Rules/AvoidReservedWordsAsFunctionNames.cshttps://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files#diff-3062a08f84e3b8cb080580ae1909c029657e017654b93235332b7221e4416934
View file https://github.com/liamjpeters/PSScriptAnalyzer/blob/8f89a1b964ac364ce63a76404bf74f47f7380a8f/Rules/AvoidReservedWordsAsFunctionNames.cs
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/{{ revealButtonHref }}
Please reload this pagehttps://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files
https://github.com/PowerShell/PSScriptAnalyzer/blob/main/.github/CODEOWNERS#L2
Rules/Strings.resxhttps://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files#diff-dcff94e6a5c5ee1dc9226dea0752aba08f8f1f53020b4a0e67f1ac944036b8c3
View file https://github.com/liamjpeters/PSScriptAnalyzer/blob/8f89a1b964ac364ce63a76404bf74f47f7380a8f/Rules/Strings.resx
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/{{ revealButtonHref }}
https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files#diff-dcff94e6a5c5ee1dc9226dea0752aba08f8f1f53020b4a0e67f1ac944036b8c3
https://github.com/PowerShell/PSScriptAnalyzer/blob/main/.github/CODEOWNERS#L2
Tests/Engine/GetScriptAnalyzerRule.tests.ps1https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files#diff-2999e95c336a14ae8a92b0c336e6709d25ccba6062c55462f0b9cc6d2f87ed68
View file https://github.com/liamjpeters/PSScriptAnalyzer/blob/8f89a1b964ac364ce63a76404bf74f47f7380a8f/Tests/Engine/GetScriptAnalyzerRule.tests.ps1
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/{{ revealButtonHref }}
https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files#diff-2999e95c336a14ae8a92b0c336e6709d25ccba6062c55462f0b9cc6d2f87ed68
Please reload this pagehttps://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files
https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files#diff-2999e95c336a14ae8a92b0c336e6709d25ccba6062c55462f0b9cc6d2f87ed68
https://github.com/PowerShell/PSScriptAnalyzer/blob/main/.github/CODEOWNERS#L2
Tests/Rules/AvoidReservedWordsAsFunctionNames.tests.ps1https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files#diff-3fa22d63fb060b1e31ea282cabc650c885e8d18169705e51122269c28d84c784
View file https://github.com/liamjpeters/PSScriptAnalyzer/blob/8f89a1b964ac364ce63a76404bf74f47f7380a8f/Tests/Rules/AvoidReservedWordsAsFunctionNames.tests.ps1
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/{{ revealButtonHref }}
Please reload this pagehttps://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files
https://github.com/PowerShell/PSScriptAnalyzer/blob/main/.github/CODEOWNERS#L6
docs/Rules/AvoidReservedWordsAsFunctionNames.mdhttps://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files#diff-e16968604856cde0429cf6750d2a1e5ce5019d48ab1771dd249767a64b0cacaa
View file https://github.com/liamjpeters/PSScriptAnalyzer/blob/8f89a1b964ac364ce63a76404bf74f47f7380a8f/docs/Rules/AvoidReservedWordsAsFunctionNames.md
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/{{ revealButtonHref }}
https://github.com/PowerShell/PSScriptAnalyzer/blob/main/.github/CODEOWNERS#L6
docs/Rules/README.mdhttps://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files#diff-aa3ee3522a3ec73c6f36f2fe020f02ee8517299d57cfe67d99ff0efd2038a0d5
View file https://github.com/liamjpeters/PSScriptAnalyzer/blob/8f89a1b964ac364ce63a76404bf74f47f7380a8f/docs/Rules/README.md
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/{{ revealButtonHref }}
https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files#diff-aa3ee3522a3ec73c6f36f2fe020f02ee8517299d57cfe67d99ff0efd2038a0d5
https://github.com/PowerShell/PSScriptAnalyzer/pull/2128/files#diff-aa3ee3522a3ec73c6f36f2fe020f02ee8517299d57cfe67d99ff0efd2038a0d5
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.