| OLD | NEW | 
|---|
| 1 // Copyright 2007-2008 the V8 project authors. All rights reserved. | 1 // Copyright 2007-2008 the V8 project authors. All rights reserved. | 
| 2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without | 
| 3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are | 
| 4 // met: | 4 // met: | 
| 5 // | 5 // | 
| 6 //     * Redistributions of source code must retain the above copyright | 6 //     * Redistributions of source code must retain the above copyright | 
| 7 //       notice, this list of conditions and the following disclaimer. | 7 //       notice, this list of conditions and the following disclaimer. | 
| 8 //     * Redistributions in binary form must reproduce the above | 8 //     * Redistributions in binary form must reproduce the above | 
| 9 //       copyright notice, this list of conditions and the following | 9 //       copyright notice, this list of conditions and the following | 
| 10 //       disclaimer in the documentation and/or other materials provided | 10 //       disclaimer in the documentation and/or other materials provided | 
| (...skipping 30 matching lines...) Expand all  Loading... | 
| 41 | 41 | 
| 42 // Callback function on handling weak global handles. | 42 // Callback function on handling weak global handles. | 
| 43 // typedef bool (*WeakSlotCallback)(Object** pointer); | 43 // typedef bool (*WeakSlotCallback)(Object** pointer); | 
| 44 | 44 | 
| 45 // An object group is treated like a single JS object: if one of object in | 45 // An object group is treated like a single JS object: if one of object in | 
| 46 // the group is alive, all objects in the same group are considered alive. | 46 // the group is alive, all objects in the same group are considered alive. | 
| 47 // An object group is used to simulate object relationship in a DOM tree. | 47 // An object group is used to simulate object relationship in a DOM tree. | 
| 48 class ObjectGroup : public Malloced { | 48 class ObjectGroup : public Malloced { | 
| 49  public: | 49  public: | 
| 50   ObjectGroup() : objects_(4) {} | 50   ObjectGroup() : objects_(4) {} | 
| 51   explicit ObjectGroup(size_t capacity) : objects_(capacity) {} | 51   explicit ObjectGroup(size_t capacity) | 
|  | 52       : objects_(static_cast<int>(capacity)) { } | 
| 52 | 53 | 
| 53   List<Object**> objects_; | 54   List<Object**> objects_; | 
| 54 }; | 55 }; | 
| 55 | 56 | 
| 56 | 57 | 
| 57 typedef void (*WeakReferenceGuest)(Object* object, void* parameter); | 58 typedef void (*WeakReferenceGuest)(Object* object, void* parameter); | 
| 58 | 59 | 
| 59 class GlobalHandles : public AllStatic { | 60 class GlobalHandles : public AllStatic { | 
| 60  public: | 61  public: | 
| 61   // Creates a new global handle that is alive until Destroy is called. | 62   // Creates a new global handle that is alive until Destroy is called. | 
| (...skipping 106 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 168   static Node* first_deallocated() { return first_deallocated_; } | 169   static Node* first_deallocated() { return first_deallocated_; } | 
| 169   static void set_first_deallocated(Node* value) { | 170   static void set_first_deallocated(Node* value) { | 
| 170     first_deallocated_ = value; | 171     first_deallocated_ = value; | 
| 171   } | 172   } | 
| 172 }; | 173 }; | 
| 173 | 174 | 
| 174 | 175 | 
| 175 } }  // namespace v8::internal | 176 } }  // namespace v8::internal | 
| 176 | 177 | 
| 177 #endif  // V8_GLOBAL_HANDLES_H_ | 178 #endif  // V8_GLOBAL_HANDLES_H_ | 
| OLD | NEW | 
|---|