Index: src/contexts.h |
diff --git a/src/contexts.h b/src/contexts.h |
index 520a8c80cdb57b16c9c94ae6f579ddf683b134a4..067fbd9b29f4c2d29c93f01ea6f2c229959d0c3d 100644 |
--- a/src/contexts.h |
+++ b/src/contexts.h |
@@ -223,6 +223,7 @@ enum ContextLookupFlags { |
V(STRICT_FUNCTION_WITHOUT_PROTOTYPE_MAP_INDEX, Map, \ |
strict_function_without_prototype_map) \ |
V(STRICT_GENERATOR_FUNCTION_MAP_INDEX, Map, strict_generator_function_map) \ |
+ V(CLASS_FUNCTION_MAP_INDEX, Map, class_function_map) \ |
V(STRING_FUNCTION_INDEX, JSFunction, string_function) \ |
V(STRING_FUNCTION_PROTOTYPE_MAP_INDEX, Map, string_function_prototype_map) \ |
V(SYMBOL_FUNCTION_INDEX, JSFunction, symbol_function) \ |
@@ -514,8 +515,10 @@ class Context: public FixedArray { |
} |
if (IsClassConstructor(kind)) { |
- // Use strict function map (no own "caller" / "arguments") |
- return STRICT_FUNCTION_MAP_INDEX; |
+ // Like the strict function map, but with no 'name' accessor. 'name' |
+ // needs to be the last property and it is added during instantiation, |
+ // in case a static property with the same name exists" |
+ return CLASS_FUNCTION_MAP_INDEX; |
} |
if (IsArrowFunction(kind) || IsConciseMethod(kind) || |