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

Side by Side Diff: src/contexts.h

Issue 384963002: ES6 Unscopables (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 4 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/bootstrapper.cc ('k') | src/contexts.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef V8_CONTEXTS_H_ 5 #ifndef V8_CONTEXTS_H_
6 #define V8_CONTEXTS_H_ 6 #define V8_CONTEXTS_H_
7 7
8 #include "src/heap/heap.h" 8 #include "src/heap/heap.h"
9 #include "src/objects.h" 9 #include "src/objects.h"
10 10
(...skipping 182 matching lines...) Expand 10 before | Expand all | Expand 10 after
193 V(NATIVE_OBJECT_OBSERVE_INDEX, JSFunction, native_object_observe) \ 193 V(NATIVE_OBJECT_OBSERVE_INDEX, JSFunction, native_object_observe) \
194 V(NATIVE_OBJECT_GET_NOTIFIER_INDEX, JSFunction, native_object_get_notifier) \ 194 V(NATIVE_OBJECT_GET_NOTIFIER_INDEX, JSFunction, native_object_get_notifier) \
195 V(NATIVE_OBJECT_NOTIFIER_PERFORM_CHANGE, JSFunction, \ 195 V(NATIVE_OBJECT_NOTIFIER_PERFORM_CHANGE, JSFunction, \
196 native_object_notifier_perform_change) \ 196 native_object_notifier_perform_change) \
197 V(SLOPPY_GENERATOR_FUNCTION_MAP_INDEX, Map, sloppy_generator_function_map) \ 197 V(SLOPPY_GENERATOR_FUNCTION_MAP_INDEX, Map, sloppy_generator_function_map) \
198 V(STRICT_GENERATOR_FUNCTION_MAP_INDEX, Map, strict_generator_function_map) \ 198 V(STRICT_GENERATOR_FUNCTION_MAP_INDEX, Map, strict_generator_function_map) \
199 V(GENERATOR_OBJECT_PROTOTYPE_MAP_INDEX, Map, generator_object_prototype_map) \ 199 V(GENERATOR_OBJECT_PROTOTYPE_MAP_INDEX, Map, generator_object_prototype_map) \
200 V(ITERATOR_RESULT_MAP_INDEX, Map, iterator_result_map) \ 200 V(ITERATOR_RESULT_MAP_INDEX, Map, iterator_result_map) \
201 V(MAP_ITERATOR_MAP_INDEX, Map, map_iterator_map) \ 201 V(MAP_ITERATOR_MAP_INDEX, Map, map_iterator_map) \
202 V(SET_ITERATOR_MAP_INDEX, Map, set_iterator_map) \ 202 V(SET_ITERATOR_MAP_INDEX, Map, set_iterator_map) \
203 V(ITERATOR_SYMBOL_INDEX, Symbol, iterator_symbol) 203 V(ITERATOR_SYMBOL_INDEX, Symbol, iterator_symbol) \
204 V(UNSCOPABLES_SYMBOL_INDEX, Symbol, unscopables_symbol)
204 205
205 // JSFunctions are pairs (context, function code), sometimes also called 206 // JSFunctions are pairs (context, function code), sometimes also called
206 // closures. A Context object is used to represent function contexts and 207 // closures. A Context object is used to represent function contexts and
207 // dynamically pushed 'with' contexts (or 'scopes' in ECMA-262 speak). 208 // dynamically pushed 'with' contexts (or 'scopes' in ECMA-262 speak).
208 // 209 //
209 // At runtime, the contexts build a stack in parallel to the execution 210 // At runtime, the contexts build a stack in parallel to the execution
210 // stack, with the top-most context being the current context. All contexts 211 // stack, with the top-most context being the current context. All contexts
211 // have the following slots: 212 // have the following slots:
212 // 213 //
213 // [ closure ] This is the current function. It is the same for all 214 // [ closure ] This is the current function. It is the same for all
(...skipping 173 matching lines...) Expand 10 before | Expand all | Expand 10 after
387 NATIVE_OBJECT_OBSERVE_INDEX, 388 NATIVE_OBJECT_OBSERVE_INDEX,
388 NATIVE_OBJECT_GET_NOTIFIER_INDEX, 389 NATIVE_OBJECT_GET_NOTIFIER_INDEX,
389 NATIVE_OBJECT_NOTIFIER_PERFORM_CHANGE, 390 NATIVE_OBJECT_NOTIFIER_PERFORM_CHANGE,
390 SLOPPY_GENERATOR_FUNCTION_MAP_INDEX, 391 SLOPPY_GENERATOR_FUNCTION_MAP_INDEX,
391 STRICT_GENERATOR_FUNCTION_MAP_INDEX, 392 STRICT_GENERATOR_FUNCTION_MAP_INDEX,
392 GENERATOR_OBJECT_PROTOTYPE_MAP_INDEX, 393 GENERATOR_OBJECT_PROTOTYPE_MAP_INDEX,
393 ITERATOR_RESULT_MAP_INDEX, 394 ITERATOR_RESULT_MAP_INDEX,
394 MAP_ITERATOR_MAP_INDEX, 395 MAP_ITERATOR_MAP_INDEX,
395 SET_ITERATOR_MAP_INDEX, 396 SET_ITERATOR_MAP_INDEX,
396 ITERATOR_SYMBOL_INDEX, 397 ITERATOR_SYMBOL_INDEX,
398 UNSCOPABLES_SYMBOL_INDEX,
397 399
398 // Properties from here are treated as weak references by the full GC. 400 // Properties from here are treated as weak references by the full GC.
399 // Scavenge treats them as strong references. 401 // Scavenge treats them as strong references.
400 OPTIMIZED_FUNCTIONS_LIST, // Weak. 402 OPTIMIZED_FUNCTIONS_LIST, // Weak.
401 OPTIMIZED_CODE_LIST, // Weak. 403 OPTIMIZED_CODE_LIST, // Weak.
402 DEOPTIMIZED_CODE_LIST, // Weak. 404 DEOPTIMIZED_CODE_LIST, // Weak.
403 MAP_CACHE_INDEX, // Weak. 405 MAP_CACHE_INDEX, // Weak.
404 NEXT_CONTEXT_LINK, // Weak. 406 NEXT_CONTEXT_LINK, // Weak.
405 407
406 // Total number of slots. 408 // Total number of slots.
(...skipping 173 matching lines...) Expand 10 before | Expand all | Expand 10 after
580 static bool IsBootstrappingOrGlobalObject(Isolate* isolate, Object* object); 582 static bool IsBootstrappingOrGlobalObject(Isolate* isolate, Object* object);
581 #endif 583 #endif
582 584
583 STATIC_ASSERT(kHeaderSize == Internals::kContextHeaderSize); 585 STATIC_ASSERT(kHeaderSize == Internals::kContextHeaderSize);
584 STATIC_ASSERT(EMBEDDER_DATA_INDEX == Internals::kContextEmbedderDataIndex); 586 STATIC_ASSERT(EMBEDDER_DATA_INDEX == Internals::kContextEmbedderDataIndex);
585 }; 587 };
586 588
587 } } // namespace v8::internal 589 } } // namespace v8::internal
588 590
589 #endif // V8_CONTEXTS_H_ 591 #endif // V8_CONTEXTS_H_
OLDNEW
« no previous file with comments | « src/bootstrapper.cc ('k') | src/contexts.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698