Skip to content

docs(linter/plugin): correct doc comment on getNodeLoc function#17178

Merged
graphite-app[bot] merged 1 commit intomainfrom
om/12-20-docs_linter_plugin_correct_doc_comment_on_getnodeloc_function
Dec 20, 2025
Merged

docs(linter/plugin): correct doc comment on getNodeLoc function#17178
graphite-app[bot] merged 1 commit intomainfrom
om/12-20-docs_linter_plugin_correct_doc_comment_on_getnodeloc_function

Conversation

@overlookmotel
Copy link
Member

@overlookmotel overlookmotel commented Dec 20, 2025

Fix these comments. They were out of date - there's no longer a loc getter on AST node objects - the getter is on the prototype.

Also alter this function to take a NodeOrToken, not Node - it's also used for tokens.

@github-actions github-actions bot added A-linter Area - Linter A-cli Area - CLI A-linter-plugins Area - Linter JS plugins labels Dec 20, 2025
Copy link
Member Author


How to use the Graphite Merge Queue

Add either label to this PR to merge it via the merge queue:

  • 0-merge - adds this PR to the back of the merge queue
  • hotfix - for urgent hot fixes, skip the queue and merge this PR next

You must have a Graphite account in order to use the merge queue. Sign up using this link.

An organization admin has enabled the Graphite Merge Queue in this repository.

Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue.

This stack of pull requests is managed by Graphite. Learn more about stacking.

@github-actions github-actions bot added the C-docs Category - Documentation. Related to user-facing or internal documentation label Dec 20, 2025
@overlookmotel overlookmotel marked this pull request as ready for review December 20, 2025 14:34
Copilot AI review requested due to automatic review settings December 20, 2025 14:34
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates documentation comments in the getNodeLoc function to accurately reflect the current implementation where the loc getter exists on the prototype rather than on individual AST node objects.

Key changes:

  • Updated JSDoc comment to clarify that the function "defines" a property rather than "overwrites" a getter
  • Expanded inline comments to explain why the property is non-enumerable and non-configurable

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@overlookmotel overlookmotel force-pushed the om/12-20-docs_linter_plugin_correct_doc_comment_on_getnodeloc_function branch from d397ae3 to 4b2ad03 Compare December 20, 2025 14:53
@overlookmotel overlookmotel self-assigned this Dec 20, 2025
@graphite-app graphite-app bot added the 0-merge Merge with Graphite Merge Queue label Dec 20, 2025
@graphite-app
Copy link
Contributor

graphite-app bot commented Dec 20, 2025

Merge activity

…7178)

Fix these comments. They were out of date - there's no longer a `loc` getter on AST node objects - the getter is on the prototype.

Also alter this function to take a `NodeOrToken`, not `Node` - it's also used for tokens.
@graphite-app graphite-app bot force-pushed the om/12-20-docs_linter_plugin_correct_doc_comment_on_getnodeloc_function branch from 4b2ad03 to 1714719 Compare December 20, 2025 15:08
@graphite-app graphite-app bot merged commit 1714719 into main Dec 20, 2025
18 checks passed
@graphite-app graphite-app bot deleted the om/12-20-docs_linter_plugin_correct_doc_comment_on_getnodeloc_function branch December 20, 2025 15:14
@graphite-app graphite-app bot removed the 0-merge Merge with Graphite Merge Queue label Dec 20, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-cli Area - CLI A-linter Area - Linter A-linter-plugins Area - Linter JS plugins C-docs Category - Documentation. Related to user-facing or internal documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants