Bug 252213 - [WGSL] Fix line number reporting in errors
Summary: [WGSL] Fix line number reporting in errors
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebGPU (show other bugs)
Version: Other
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Dan Glastonbury
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2023-02-13 16:40 PST by Dan Glastonbury
Modified: 2023-02-13 18:12 PST (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Dan Glastonbury 2023-02-13 16:40:13 PST
Text editors use one-based line numbering, not zero.  When setting source
code to be tokenized, set the current position to offset of 0 on line 1. This
allows a position with m_line set to 0 to represent and empty or invalid
position.
Comment 1 Radar WebKit Bug Importer 2023-02-13 16:40:59 PST
<rdar://problem/105423092>
Comment 2 Dan Glastonbury 2023-02-13 16:42:32 PST
Pull request: https://github.com/WebKit/WebKit/pull/10064
Comment 3 EWS 2023-02-13 18:12:38 PST
Committed 260237@main (5152a874639a): <https://commits.webkit.org/260237@main>

Reviewed commits have been landed. Closing PR #10064 and removing active labels.