@@ -4288,6 +4288,9 @@ class ScopeInfo : public FixedArray {
42884288 // Return the name of the given stack local.
42894289 String* StackLocalName (int var);
42904290
4291+ // Return the name of the given stack local.
4292+ int StackLocalIndex (int var);
4293+
42914294 // Return the name of the given context local.
42924295 String* ContextLocalName (int var);
42934296
@@ -4396,33 +4399,38 @@ class ScopeInfo : public FixedArray {
43964399 // slot is used per parameter, so in total this part occupies
43974400 // ParameterCount() slots in the array. For other scopes than function
43984401 // scopes ParameterCount() is 0.
4399- // 2. StackLocalEntries:
4402+ // 2. StackLocalFirstSlot:
4403+ // Index of a first stack slot for stack local. Stack locals belonging to
4404+ // this scope are located on a stack at slots starting from this index.
4405+ // 3. StackLocalEntries:
44004406 // Contains the names of local variables that are allocated on the stack,
4401- // in increasing order of the stack slot index. One slot is used per stack
4402- // local, so in total this part occupies StackLocalCount() slots in the
4403- // array.
4404- // 3. ContextLocalNameEntries:
4407+ // in increasing order of the stack slot index. First local variable has
4408+ // a stack slot index defined in StackLocalFirstSlot (point 2 above).
4409+ // One slot is used per stack local, so in total this part occupies
4410+ // StackLocalCount() slots in the array.
4411+ // 4. ContextLocalNameEntries:
44054412 // Contains the names of local variables and parameters that are allocated
44064413 // in the context. They are stored in increasing order of the context slot
44074414 // index starting with Context::MIN_CONTEXT_SLOTS. One slot is used per
44084415 // context local, so in total this part occupies ContextLocalCount() slots
44094416 // in the array.
4410- // 4 . ContextLocalInfoEntries:
4417+ // 5 . ContextLocalInfoEntries:
44114418 // Contains the variable modes and initialization flags corresponding to
44124419 // the context locals in ContextLocalNameEntries. One slot is used per
44134420 // context local, so in total this part occupies ContextLocalCount()
44144421 // slots in the array.
4415- // 5 . StrongModeFreeVariableNameEntries:
4422+ // 6 . StrongModeFreeVariableNameEntries:
44164423 // Stores the names of strong mode free variables.
4417- // 6 . StrongModeFreeVariablePositionEntries:
4424+ // 7 . StrongModeFreeVariablePositionEntries:
44184425 // Stores the locations (start and end position) of strong mode free
44194426 // variables.
4420- // 7 . FunctionNameEntryIndex:
4427+ // 8 . FunctionNameEntryIndex:
44214428 // If the scope belongs to a named function expression this part contains
44224429 // information about the function variable. It always occupies two array
44234430 // slots: a. The name of the function variable.
44244431 // b. The context or stack slot index for the variable.
44254432 int ParameterEntriesIndex ();
4433+ int StackLocalFirstSlotIndex ();
44264434 int StackLocalEntriesIndex ();
44274435 int ContextLocalNameEntriesIndex ();
44284436 int ContextLocalInfoEntriesIndex ();
0 commit comments