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

Side by Side Diff: src/factory.h

Issue 722723002: Move public symbols to the root set. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 1 month 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/contexts.cc ('k') | src/harmony-tostring.js » ('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 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 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_FACTORY_H_ 5 #ifndef V8_FACTORY_H_
6 #define V8_FACTORY_H_ 6 #define V8_FACTORY_H_
7 7
8 #include "src/isolate.h" 8 #include "src/isolate.h"
9 9
10 namespace v8 { 10 namespace v8 {
(...skipping 594 matching lines...) Expand 10 before | Expand all | Expand 10 after
605 #undef STRING_ACCESSOR 605 #undef STRING_ACCESSOR
606 606
607 #define SYMBOL_ACCESSOR(name) \ 607 #define SYMBOL_ACCESSOR(name) \
608 inline Handle<Symbol> name() { \ 608 inline Handle<Symbol> name() { \
609 return Handle<Symbol>(bit_cast<Symbol**>( \ 609 return Handle<Symbol>(bit_cast<Symbol**>( \
610 &isolate()->heap()->roots_[Heap::k##name##RootIndex])); \ 610 &isolate()->heap()->roots_[Heap::k##name##RootIndex])); \
611 } 611 }
612 PRIVATE_SYMBOL_LIST(SYMBOL_ACCESSOR) 612 PRIVATE_SYMBOL_LIST(SYMBOL_ACCESSOR)
613 #undef SYMBOL_ACCESSOR 613 #undef SYMBOL_ACCESSOR
614 614
615 #define SYMBOL_ACCESSOR(name, varname, description) \
616 inline Handle<Symbol> name() { \
617 return Handle<Symbol>(bit_cast<Symbol**>( \
618 &isolate()->heap()->roots_[Heap::k##name##RootIndex])); \
619 }
620 PUBLIC_SYMBOL_LIST(SYMBOL_ACCESSOR)
621 #undef SYMBOL_ACCESSOR
622
615 inline void set_string_table(Handle<StringTable> table) { 623 inline void set_string_table(Handle<StringTable> table) {
616 isolate()->heap()->set_string_table(*table); 624 isolate()->heap()->set_string_table(*table);
617 } 625 }
618 626
619 Handle<String> hidden_string() { 627 Handle<String> hidden_string() {
620 return Handle<String>(&isolate()->heap()->hidden_string_); 628 return Handle<String>(&isolate()->heap()->hidden_string_);
621 } 629 }
622 630
623 // Allocates a new SharedFunctionInfo object. 631 // Allocates a new SharedFunctionInfo object.
624 Handle<SharedFunctionInfo> NewSharedFunctionInfo( 632 Handle<SharedFunctionInfo> NewSharedFunctionInfo(
(...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after
718 // Reinitialize a JSProxy into an (empty) JS object of respective type and 726 // Reinitialize a JSProxy into an (empty) JS object of respective type and
719 // size, but keeping the original prototype. The receiver must have at least 727 // size, but keeping the original prototype. The receiver must have at least
720 // the size of the new object. The object is reinitialized and behaves as an 728 // the size of the new object. The object is reinitialized and behaves as an
721 // object that has been freshly allocated. 729 // object that has been freshly allocated.
722 void ReinitializeJSProxy(Handle<JSProxy> proxy, InstanceType type, int size); 730 void ReinitializeJSProxy(Handle<JSProxy> proxy, InstanceType type, int size);
723 }; 731 };
724 732
725 } } // namespace v8::internal 733 } } // namespace v8::internal
726 734
727 #endif // V8_FACTORY_H_ 735 #endif // V8_FACTORY_H_
OLDNEW
« no previous file with comments | « src/contexts.cc ('k') | src/harmony-tostring.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698