Skip to content

refactor(linter/no-map-spread): use is_scope_descendant_of api#22314

Merged
graphite-app[bot] merged 1 commit into
mainfrom
c/no-map-spread-is_scope_descendant_of
Jun 10, 2026
Merged

refactor(linter/no-map-spread): use is_scope_descendant_of api#22314
graphite-app[bot] merged 1 commit into
mainfrom
c/no-map-spread-is_scope_descendant_of

Conversation

@camc314

@camc314 camc314 commented May 11, 2026

Copy link
Copy Markdown
Contributor

stacked on #22313

@camc314 camc314 self-assigned this May 11, 2026
Copilot AI review requested due to automatic review settings May 11, 2026 09:54
@camc314 camc314 added the A-linter Area - Linter label May 11, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Refactors the no-map-spread linter rule’s callback-scope check to use the new semantic scoping helper is_scope_descendant_of, aligning linter logic with the centralized scoping API introduced in #22313.

Changes:

  • Replace manual scope_ancestors(...).any(...) traversal with is_scope_descendant_of(...).
  • Preserve the prior behavior by explicitly allowing the “same scope” case (declaration_scope == cb_scope_id) since the helper defines “descendant” as excluding self.

@camc314 camc314 force-pushed the c/scope-descendant-of branch from 712bae8 to 14d2c00 Compare May 11, 2026 09:56
@camc314 camc314 requested a review from Dunqing as a code owner May 11, 2026 09:56
@camc314 camc314 force-pushed the c/no-map-spread-is_scope_descendant_of branch 2 times, most recently from 88f9f35 to 70ff54a Compare May 11, 2026 10:04
@codspeed-hq

codspeed-hq Bot commented May 11, 2026

Copy link
Copy Markdown

Merging this PR will not alter performance

✅ 4 untouched benchmarks
⏩ 47 skipped benchmarks1


Comparing c/no-map-spread-is_scope_descendant_of (70ff54a) with c/scope-descendant-of (14d2c00)

Open in CodSpeed

Footnotes

  1. 47 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.

@camc314 camc314 added 0-merge Merge with Graphite Merge Queue and removed 0-merge Merge with Graphite Merge Queue labels May 18, 2026
@graphite-app graphite-app Bot force-pushed the c/scope-descendant-of branch from 14d2c00 to 3ccf46c Compare May 18, 2026 09:24
@Boshen Boshen added the 0-merge Merge with Graphite Merge Queue label Jun 9, 2026
@graphite-app graphite-app Bot force-pushed the c/scope-descendant-of branch from 3ccf46c to 44313da Compare June 10, 2026 12:48
Base automatically changed from c/scope-descendant-of to main June 10, 2026 12:51

Boshen commented Jun 10, 2026

Copy link
Copy Markdown
Member

Merge activity

@github-actions github-actions Bot added the A-semantic Area - Semantic label Jun 10, 2026
@graphite-app graphite-app Bot force-pushed the c/no-map-spread-is_scope_descendant_of branch from 70ff54a to 6e355b4 Compare June 10, 2026 12:53
@graphite-app graphite-app Bot merged commit 6e355b4 into main Jun 10, 2026
29 checks passed
@graphite-app graphite-app Bot removed the 0-merge Merge with Graphite Merge Queue label Jun 10, 2026
@graphite-app graphite-app Bot deleted the c/no-map-spread-is_scope_descendant_of branch June 10, 2026 12:57
camc314 added a commit that referenced this pull request Jul 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-linter Area - Linter A-semantic Area - Semantic

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants