Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Commit transaction after parsing Typescript type definition, interface, or namespace #1112

Merged
merged 1 commit into from
Dec 6, 2023

Conversation

ruipserra
Copy link
Contributor

Fixes #1108

Parser::parse_and_visit_typescript_interface_or_namespace_or_type_statement starts a lexer transaction, but that transaction wasn't committed if the statement was parsed cleanly.

A couple of minimal test repro files:

interface I {}
let i = "
type T = {};
let i = "

In master, linting these files would crash quick-lint-js.

Copy link

github-actions bot commented Dec 6, 2023

CLA Assistant Lite bot Thank you for your contribution! Like many free software projects, you must sign our Contributor License Agreement before we can accept your contribution.

EDIT: All contributors have signed quick-lint-js' Contributor License Agreement (CLA-v1.md).

@ruipserra
Copy link
Contributor Author

I have read and hereby agree to quick-lint-js' Contributor License Agreement (CLA-v1.md).

@strager
Copy link
Collaborator

strager commented Dec 6, 2023

Thank you for debugging and fixing this issue!

@strager strager merged commit 088573b into quick-lint:master Dec 6, 2023
93 checks passed
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.

bug(typescript): quick-lint crashes with unclosed TSX JavaScript expression-thingy {
2 participants