Skip to content

Improve parser robustness and highlighting performance#23

Open
romanbsd wants to merge 1 commit into
serverpod:mainfrom
romanbsd:parser-performance-regressions
Open

Improve parser robustness and highlighting performance#23
romanbsd wants to merge 1 commit into
serverpod:mainfrom
romanbsd:parser-performance-regressions

Conversation

@romanbsd

@romanbsd romanbsd commented Jul 6, 2026

Copy link
Copy Markdown

Summary

Adds regression tests and implements targeted robustness and performance improvements in the parser and highlighter.

Changes

  • Fix repeated capture text being scoped at the wrong offset.
  • Treat nullable pattern lists as empty lists instead of crashing.
  • Add a deliberate UnsupportedError for unknown highlighter languages.
  • Support combined theme fontStyle values such as bold italic underline.
  • Cache theme scope fallback lookup.
  • Avoid repeated string concatenation in bracket formatting.
  • Share multiline scanner loops through common helpers.
  • Replace an empty placeholder test file with focused regression coverage.

Validation

  • flutter analyze
  • flutter test

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant