ladybird/Tests/LibJS/Bytecode/expected/captured-variables.txt
Andreas Kling 21cbfb3cb1 LibJS: Drop source ranges from bytecode source maps
Store source map locations as bytecode offset, line, and column.
Runtime consumers only emit the start line and column, so source end
positions and source text offsets do not need to be carried through
Executable source maps, bytecode cache serialization, or the Rust FFI.

Keep SourceCode's internal position cache able to track source text
offsets so callers can still translate source offsets to line and
column pairs when needed. Hash dump-bytecode IDs from the name, first
source position, and bytecode size instead of source slices that need
end offsets.

Bump the bytecode cache format version for the slimmer serialized
source map entry shape.
2026-05-14 09:41:03 +02:00

38 lines
994 B
Text

$c7fd0018 captured-variables.js:12:1
Registers: 7
Blocks: 1
Constants:
[0] = Undefined
block0:
[ 0] GetGlobal dst:reg6, `outer`
[ 18] Call dst:reg5, callee:reg6, this_value:Undefined, outer
[ 38] End value:reg5
outer$e7583c0c captured-variables.js:5:5
Registers: 7
Blocks: 1
Locals: inner~0
Constants:
[0] = Undefined
[1] = Int32(1)
block0:
[ 0] GetLexicalEnvironment dst:reg4
[ 8] Mov dst:inner~0, src:Undefined
[ 18] CreateLexicalEnvironment dst:reg5, parent:reg4, capacity:1
[ 28] CreateVariable `captured`, is_immutable:false, is_global:false, is_strict:false
[ 38] NewFunction dst:inner~0, shared_function_data_index:0
[ 50] InitializeLexicalBinding `captured`, src:Int32(1)
[ 68] Call dst:reg6, callee:inner~0, this_value:Undefined, inner
[ 88] Return value:reg6
inner$e471f8e5 captured-variables.js:7:9
Registers: 6
Blocks: 1
block0:
[ 0] GetBinding dst:reg5, `captured`
[ 18] Return value:reg5