Skip to content

refactor(parser): rename ModifierKinds::empty to none#20740

Merged
graphite-app[bot] merged 1 commit intomainfrom
om/03-23-refactor_parser_rename_modifierkinds_empty_to_none_
Mar 26, 2026
Merged

refactor(parser): rename ModifierKinds::empty to none#20740
graphite-app[bot] merged 1 commit intomainfrom
om/03-23-refactor_parser_rename_modifierkinds_empty_to_none_

Conversation

@overlookmotel
Copy link
Copy Markdown
Member

@overlookmotel overlookmotel commented Mar 25, 2026

Pure refactor. Rename ModifierKinds::empty to ModifierKinds::none. "None" feels like a better description of "no modifier kinds" than "empty".

This PR is pure renaming - no substantive changes.

Copy link
Copy Markdown
Member Author

overlookmotel commented Mar 25, 2026


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 changes, fast-track this PR to the front of the merge queue

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 A-parser Area - Parser label Mar 25, 2026
@github-actions github-actions bot added the C-cleanup Category - technical debt or refactoring. Solution not expected to change behavior label Mar 25, 2026
@overlookmotel overlookmotel marked this pull request as ready for review March 25, 2026 15:49
Copilot AI review requested due to automatic review settings March 25, 2026 15:49
@codspeed-hq
Copy link
Copy Markdown

codspeed-hq bot commented Mar 25, 2026

Merging this PR will not alter performance

✅ 44 untouched benchmarks
⏩ 12 skipped benchmarks1


Comparing om/03-23-refactor_parser_rename_modifierkinds_empty_to_none_ (3479285) with main (cfa7b0f)

Open in CodSpeed

Footnotes

  1. 12 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports.

Copy link
Copy Markdown
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

Renames the ModifierKinds “empty set” constructor from empty() to none() across the parser, updating all internal call sites to use the new name.

Changes:

  • Rename ModifierKinds::empty() to ModifierKinds::none()
  • Update parser call sites to use ModifierKinds::none() when validating/collecting modifiers

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.

File Description
crates/oxc_parser/src/modifiers.rs Renames the public ModifierKinds constructor and updates internal initializations
crates/oxc_parser/src/js/object.rs Updates modifier verification to pass ModifierKinds::none()
crates/oxc_parser/src/js/function.rs Updates allowed-modifier set construction to use ModifierKinds::none()
crates/oxc_parser/src/js/class.rs Updates modifier verification to pass ModifierKinds::none()

@overlookmotel overlookmotel force-pushed the om/03-23-refactor_parser_rename_modifierflags_to_modifierkinds_ branch from bcd1734 to f72933b Compare March 25, 2026 19:01
@overlookmotel overlookmotel force-pushed the om/03-23-refactor_parser_rename_modifierkinds_empty_to_none_ branch from 0d54c06 to 6627f58 Compare March 25, 2026 19:01
@graphite-app graphite-app bot force-pushed the om/03-23-refactor_parser_rename_modifierflags_to_modifierkinds_ branch from f72933b to 0b12df6 Compare March 25, 2026 19:12
@graphite-app graphite-app bot force-pushed the om/03-23-refactor_parser_rename_modifierkinds_empty_to_none_ branch from 6627f58 to 1858708 Compare March 25, 2026 19:12
@overlookmotel overlookmotel force-pushed the om/03-23-refactor_parser_rename_modifierkinds_empty_to_none_ branch from 1858708 to e2043a2 Compare March 25, 2026 19:13
@overlookmotel overlookmotel force-pushed the om/03-23-refactor_parser_rename_modifierflags_to_modifierkinds_ branch from 0b12df6 to 9d5b470 Compare March 25, 2026 19:13
@graphite-app
Copy link
Copy Markdown
Contributor

graphite-app bot commented Mar 26, 2026

Merge activity

  • Mar 26, 1:08 PM UTC: camc314 added this pull request to the Graphite merge queue.
  • Mar 26, 1:13 PM UTC: The Graphite merge queue removed this pull request due to downstack failures on PR #20739.
  • Mar 26, 1:13 PM UTC: The Graphite merge queue removed this pull request due to downstack failures on PR #20739.
  • Mar 26, 1:25 PM UTC: The merge label '0-merge' was detected. This PR will be added to the Graphite merge queue once it meets the requirements.
  • Mar 26, 1:29 PM UTC: camc314 added this pull request to the Graphite merge queue.
  • Mar 26, 1:33 PM UTC: The Graphite merge queue couldn't merge this PR because it had merge conflicts.
  • Mar 26, 1:34 PM UTC: The merge label '0-merge' was removed. This PR will no longer be merged by the Graphite merge queue
  • Mar 26, 1:34 PM UTC: Graphite rebased this pull request, because this pull request is set to merge when ready.
  • Mar 26, 1:36 PM UTC: The merge label '0-merge' was detected. This PR will be added to the Graphite merge queue once it meets the requirements.
  • Mar 26, 1:37 PM UTC: The merge label '0-merge' was removed. This PR will no longer be merged by the Graphite merge queue
  • Mar 26, 1:37 PM UTC: The merge label '0-merge' was detected. This PR will be added to the Graphite merge queue once it meets the requirements.
  • Mar 26, 1:37 PM UTC: camc314 added this pull request to the Graphite merge queue.
  • Mar 26, 1:48 PM UTC: Merged by the Graphite merge queue.

@camc314 camc314 force-pushed the om/03-23-refactor_parser_rename_modifierflags_to_modifierkinds_ branch from 9d5b470 to 0c15f8f Compare March 26, 2026 13:24
@camc314 camc314 added the 0-merge Merge with Graphite Merge Queue label Mar 26, 2026
@camc314 camc314 force-pushed the om/03-23-refactor_parser_rename_modifierkinds_empty_to_none_ branch from e2043a2 to 90f6820 Compare March 26, 2026 13:25
@graphite-app graphite-app bot changed the base branch from om/03-23-refactor_parser_rename_modifierflags_to_modifierkinds_ to graphite-base/20740 March 26, 2026 13:28
@graphite-app graphite-app bot changed the base branch from graphite-base/20740 to main March 26, 2026 13:32
@graphite-app graphite-app bot removed the 0-merge Merge with Graphite Merge Queue label Mar 26, 2026
@camc314 camc314 force-pushed the om/03-23-refactor_parser_rename_modifierkinds_empty_to_none_ branch from 90f6820 to 3479285 Compare March 26, 2026 13:34
@camc314 camc314 added the 0-merge Merge with Graphite Merge Queue label Mar 26, 2026 — with Graphite App
graphite-app bot pushed a commit that referenced this pull request Mar 26, 2026
Pure refactor. Rename `ModifierKinds::empty` to `ModifierKinds::none`. "None" feels like a better description of "no modifier kinds" than "empty".

This PR is pure renaming - no substantive changes.
@graphite-app graphite-app bot force-pushed the om/03-23-refactor_parser_rename_modifierkinds_empty_to_none_ branch from 3479285 to 21f9a96 Compare March 26, 2026 13:38
Pure refactor. Rename `ModifierKinds::empty` to `ModifierKinds::none`. "None" feels like a better description of "no modifier kinds" than "empty".

This PR is pure renaming - no substantive changes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-parser Area - Parser C-cleanup Category - technical debt or refactoring. Solution not expected to change behavior

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants