Template literals (`hello ${name}`) are the last Tier 1 blocker before
shimming Test262's assert.js/sta.js harness files. The tokenizer eagerly
scans each template into a composite token (quasis + raw expression
strings + absolute byte offsets), and the parser re-tokenizes expressions
with span rebasing for correct source locations. Includes UTF-8-safe
quasi string building, nesting depth limits, and structural comment
skipping in nested expressions.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
17 lines
190 B
Plaintext
17 lines
190 B
Plaintext
hello world
|
|
hello world
|
|
2 + 3 = 5
|
|
num: 42
|
|
bool: true
|
|
val: null
|
|
val: undefined
|
|
line1
|
|
line2
|
|
backtick: ` dollar: ${ newline:
|
|
|
|
outer nested inner end
|
|
|
|
hi Alice
|
|
obj: [object Object]
|
|
keys: object
|