Skip to content

Conversation

@CPunisher
Copy link
Member

Description:

I find that this property is only written but isn't read.

Copilot AI review requested due to automatic review settings October 28, 2025 12:10
@CPunisher CPunisher requested a review from a team as a code owner October 28, 2025 12:10
@changeset-bot
Copy link

changeset-bot bot commented Oct 28, 2025

🦋 Changeset detected

Latest commit: 0471074

The changes in this PR will be included in the next version bump.

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

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 removes the unused had_line_break_before_last field from the lexer's State struct to improve performance. The field was being written to but never read, making it unnecessary overhead.

  • Removes the had_line_break_before_last field declaration from the State struct
  • Removes all assignments to had_line_break_before_last throughout the lexer code
  • Removes initialization of the field in State::new()

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

@codspeed-hq
Copy link

codspeed-hq bot commented Oct 28, 2025

CodSpeed Performance Report

Merging #11200 will not alter performance

Comparing CPunisher:10-29-perf/had-line-break-before-last (0471074) with main (acca984)

Summary

✅ 138 untouched
⏩ 13 skipped1

Footnotes

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

@kdy1 kdy1 added this to the Planned milestone Oct 28, 2025
@kdy1 kdy1 requested a review from a team as a code owner October 28, 2025 12:58
@kdy1 kdy1 merged commit 7b5bcd7 into swc-project:main Oct 28, 2025
18 of 22 checks passed
@CPunisher CPunisher deleted the 10-29-perf/had-line-break-before-last branch October 28, 2025 13:18
@kdy1 kdy1 modified the milestones: Planned, v1.14.0 Oct 29, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants