Index: src/contexts.h |
diff --git a/src/contexts.h b/src/contexts.h |
index 100e1a256e689167dc2176f90935c5e2eb90ca17..6a45baf0e18c69ae9cd97ff412691f4e82a9053a 100644 |
--- a/src/contexts.h |
+++ b/src/contexts.h |
@@ -88,6 +88,8 @@ enum ContextLookupFlags { |
V(JS_ARRAY_MAP_INDEX, Map, js_array_map)\ |
V(REGEXP_RESULT_MAP_INDEX, Map, regexp_result_map)\ |
V(ARGUMENTS_BOILERPLATE_INDEX, JSObject, arguments_boilerplate) \ |
+ V(ALIASED_ARGUMENTS_BOILERPLATE_INDEX, JSObject, \ |
+ aliased_arguments_boilerplate) \ |
V(STRICT_MODE_ARGUMENTS_BOILERPLATE_INDEX, JSObject, \ |
strict_mode_arguments_boilerplate) \ |
V(MESSAGE_LISTENERS_INDEX, JSObject, message_listeners) \ |
@@ -181,20 +183,15 @@ class Context: public FixedArray { |
CLOSURE_INDEX, |
FCONTEXT_INDEX, |
PREVIOUS_INDEX, |
- // The extension slot is used for either the global object (in global |
- // contexts), eval extension object (function contexts), subject of with |
- // (with contexts), or the variable name (catch contexts). |
EXTENSION_INDEX, |
GLOBAL_INDEX, |
MIN_CONTEXT_SLOTS, |
- // This slot holds the thrown value in catch contexts. |
- THROWN_OBJECT_INDEX = MIN_CONTEXT_SLOTS, |
- |
// These slots are only in global contexts. |
GLOBAL_PROXY_INDEX = MIN_CONTEXT_SLOTS, |
SECURITY_TOKEN_INDEX, |
ARGUMENTS_BOILERPLATE_INDEX, |
+ ALIASED_ARGUMENTS_BOILERPLATE_INDEX, |
STRICT_MODE_ARGUMENTS_BOILERPLATE_INDEX, |
JS_ARRAY_MAP_INDEX, |
REGEXP_RESULT_MAP_INDEX, |
@@ -271,9 +268,9 @@ class Context: public FixedArray { |
} |
void set_previous(Context* context) { set(PREVIOUS_INDEX, context); } |
- bool has_extension() { return extension() != NULL; } |
- Object* extension() { return get(EXTENSION_INDEX); } |
- void set_extension(Object* object) { set(EXTENSION_INDEX, object); } |
+ bool has_extension() { return unchecked_extension() != NULL; } |
+ JSObject* extension() { return JSObject::cast(unchecked_extension()); } |
+ void set_extension(JSObject* object) { set(EXTENSION_INDEX, object); } |
GlobalObject* global() { |
Object* result = get(GLOBAL_INDEX); |
@@ -303,10 +300,6 @@ class Context: public FixedArray { |
Map* map = this->map(); |
return map == map->GetHeap()->catch_context_map(); |
} |
- bool IsWithContext() { |
- Map* map = this->map(); |
- return map == map->GetHeap()->with_context_map(); |
- } |
// Tells whether the global context is marked with out of memory. |
inline bool has_out_of_memory(); |
@@ -395,6 +388,7 @@ class Context: public FixedArray { |
private: |
// Unchecked access to the slots. |
Object* unchecked_previous() { return get(PREVIOUS_INDEX); } |
+ Object* unchecked_extension() { return get(EXTENSION_INDEX); } |
#ifdef DEBUG |
// Bootstrapping-aware type checks. |