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

Side by Side Diff: src/heap/heap.cc

Issue 1318043002: Native context: do not put public symbols and flags on the js builtins object. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: fix and rebase Created 5 years, 3 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
« no previous file with comments | « src/heap/heap.h ('k') | src/heap/heap-inl.h » ('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 #include "src/heap/heap.h" 5 #include "src/heap/heap.h"
6 6
7 #include "src/accessors.h" 7 #include "src/accessors.h"
8 #include "src/api.h" 8 #include "src/api.h"
9 #include "src/base/bits.h" 9 #include "src/base/bits.h"
10 #include "src/base/once.h" 10 #include "src/base/once.h"
(...skipping 3202 matching lines...) Expand 10 before | Expand all | Expand 10 after
3213 Handle<String> name##d = factory->NewStringFromStaticChars(#name); \ 3213 Handle<String> name##d = factory->NewStringFromStaticChars(#name); \
3214 Handle<Object> symbol(isolate()->factory()->NewPrivateSymbol(name##d)); \ 3214 Handle<Object> symbol(isolate()->factory()->NewPrivateSymbol(name##d)); \
3215 roots_[k##name##RootIndex] = *symbol; \ 3215 roots_[k##name##RootIndex] = *symbol; \
3216 } 3216 }
3217 PRIVATE_SYMBOL_LIST(SYMBOL_INIT) 3217 PRIVATE_SYMBOL_LIST(SYMBOL_INIT)
3218 #undef SYMBOL_INIT 3218 #undef SYMBOL_INIT
3219 } 3219 }
3220 3220
3221 { 3221 {
3222 HandleScope scope(isolate()); 3222 HandleScope scope(isolate());
3223 #define SYMBOL_INIT(name, varname, description) \ 3223 #define SYMBOL_INIT(name, description) \
3224 Handle<Symbol> name = factory->NewSymbol(); \ 3224 Handle<Symbol> name = factory->NewSymbol(); \
3225 Handle<String> name##d = factory->NewStringFromStaticChars(#description); \ 3225 Handle<String> name##d = factory->NewStringFromStaticChars(#description); \
3226 name->set_name(*name##d); \ 3226 name->set_name(*name##d); \
3227 roots_[k##name##RootIndex] = *name; 3227 roots_[k##name##RootIndex] = *name;
3228 PUBLIC_SYMBOL_LIST(SYMBOL_INIT) 3228 PUBLIC_SYMBOL_LIST(SYMBOL_INIT)
3229 #undef SYMBOL_INIT 3229 #undef SYMBOL_INIT
3230 } 3230 }
3231 3231
3232 CreateFixedStubs(); 3232 CreateFixedStubs();
3233 3233
(...skipping 3540 matching lines...) Expand 10 before | Expand all | Expand 10 after
6774 *object_type = "CODE_TYPE"; \ 6774 *object_type = "CODE_TYPE"; \
6775 *object_sub_type = "CODE_AGE/" #name; \ 6775 *object_sub_type = "CODE_AGE/" #name; \
6776 return true; 6776 return true;
6777 CODE_AGE_LIST_COMPLETE(COMPARE_AND_RETURN_NAME) 6777 CODE_AGE_LIST_COMPLETE(COMPARE_AND_RETURN_NAME)
6778 #undef COMPARE_AND_RETURN_NAME 6778 #undef COMPARE_AND_RETURN_NAME
6779 } 6779 }
6780 return false; 6780 return false;
6781 } 6781 }
6782 } // namespace internal 6782 } // namespace internal
6783 } // namespace v8 6783 } // namespace v8
OLDNEW
« no previous file with comments | « src/heap/heap.h ('k') | src/heap/heap-inl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698