Skip to content

Fixup DiagnosticCodeHighlight and SourceLocation columns#8965

Merged
mischnic merged 18 commits into
v2from
loc-codeframe-one-off
May 16, 2023
Merged

Fixup DiagnosticCodeHighlight and SourceLocation columns#8965
mischnic merged 18 commits into
v2from
loc-codeframe-one-off

Conversation

@mischnic

Copy link
Copy Markdown
Member

It was always (supposed to be) the case that:

  • DiagnosticCodeHighlight is 1-based and the end location is inclusive
  • SourceLocation is 1-based and the end is exclusive

But due to two cancelling off-by-one errors, many SourceLocation had an incorrect end position.

This caused problems when bumping Babel (causing more accurate sourcemaps) which caused some wrong locations to be remapped.

@devongovett

Copy link
Copy Markdown
Member

Seems like a test is failing

@mischnic mischnic merged commit be85a8c into v2 May 16, 2023
@mischnic mischnic deleted the loc-codeframe-one-off branch May 16, 2023 14:40
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.

2 participants