Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(293)

Unified Diff: src/objects.h

Issue 1218783005: Support for global var shortcuts in script contexts. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Fixing builds Created 5 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/mips64/full-codegen-mips64.cc ('k') | src/parser.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/objects.h
diff --git a/src/objects.h b/src/objects.h
index c52ccc9ed04494d8e9a10dd753c74a3cda3326ce..dc96725023d6c7f0bf14b0383303d3ef04f2b8ab 100644
--- a/src/objects.h
+++ b/src/objects.h
@@ -4011,7 +4011,8 @@ class ScopeInfo : public FixedArray {
// If the slot is present and mode != NULL, sets *mode to the corresponding
// mode for that variable.
static int ContextSlotIndex(Handle<ScopeInfo> scope_info, Handle<String> name,
- VariableMode* mode, InitializationFlag* init_flag,
+ VariableMode* mode, VariableLocation* location,
+ InitializationFlag* init_flag,
MaybeAssignedFlag* maybe_assigned_flag);
// Lookup support for serialized scope info. Returns the
@@ -4061,6 +4062,7 @@ class ScopeInfo : public FixedArray {
V(ParameterCount) \
V(StackLocalCount) \
V(ContextLocalCount) \
+ V(ContextGlobalCount) \
V(StrongModeFreeVariableCount)
#define FIELD_ACCESSORS(name) \
@@ -4129,12 +4131,18 @@ class ScopeInfo : public FixedArray {
int StackLocalFirstSlotIndex();
int StackLocalEntriesIndex();
int ContextLocalNameEntriesIndex();
+ int ContextGlobalNameEntriesIndex();
int ContextLocalInfoEntriesIndex();
+ int ContextGlobalInfoEntriesIndex();
int StrongModeFreeVariableNameEntriesIndex();
int StrongModeFreeVariablePositionEntriesIndex();
int ReceiverEntryIndex();
int FunctionNameEntryIndex();
+ int Lookup(Handle<String> name, int start, int end, VariableMode* mode,
+ VariableLocation* location, InitializationFlag* init_flag,
+ MaybeAssignedFlag* maybe_assigned_flag);
+
// Used for the function name variable for named function expressions, and for
// the receiver.
enum VariableAllocationInfo { NONE, STACK, CONTEXT, UNUSED };
« no previous file with comments | « src/mips64/full-codegen-mips64.cc ('k') | src/parser.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698