| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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 627 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 638 near_death_callback); | 638 near_death_callback); |
| 639 } | 639 } |
| 640 | 640 |
| 641 | 641 |
| 642 void V8::ClearWeak(i::Isolate* isolate, i::Object** obj) { | 642 void V8::ClearWeak(i::Isolate* isolate, i::Object** obj) { |
| 643 LOG_API(isolate, "ClearWeak"); | 643 LOG_API(isolate, "ClearWeak"); |
| 644 isolate->global_handles()->ClearWeakness(obj); | 644 isolate->global_handles()->ClearWeakness(obj); |
| 645 } | 645 } |
| 646 | 646 |
| 647 | 647 |
| 648 void V8::DisposeGlobal(i::Isolate* isolate, i::Object** obj) { | 648 void V8::DisposeGlobal(i::Object** obj) { |
| 649 ASSERT(isolate == i::Isolate::Current()); | 649 i::GlobalHandles::Destroy(obj); |
| 650 LOG_API(isolate, "DisposeGlobal"); | |
| 651 if (!isolate->IsInitialized()) return; | |
| 652 isolate->global_handles()->Destroy(obj); | |
| 653 } | 650 } |
| 654 | 651 |
| 655 // --- H a n d l e s --- | 652 // --- H a n d l e s --- |
| 656 | 653 |
| 657 | 654 |
| 658 HandleScope::HandleScope() { | 655 HandleScope::HandleScope() { |
| 659 Initialize(reinterpret_cast<Isolate*>(i::Isolate::Current())); | 656 Initialize(reinterpret_cast<Isolate*>(i::Isolate::Current())); |
| 660 } | 657 } |
| 661 | 658 |
| 662 | 659 |
| (...skipping 7211 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 7874 | 7871 |
| 7875 v->VisitPointers(blocks_.first(), first_block_limit_); | 7872 v->VisitPointers(blocks_.first(), first_block_limit_); |
| 7876 | 7873 |
| 7877 for (int i = 1; i < blocks_.length(); i++) { | 7874 for (int i = 1; i < blocks_.length(); i++) { |
| 7878 v->VisitPointers(blocks_[i], &blocks_[i][kHandleBlockSize]); | 7875 v->VisitPointers(blocks_[i], &blocks_[i][kHandleBlockSize]); |
| 7879 } | 7876 } |
| 7880 } | 7877 } |
| 7881 | 7878 |
| 7882 | 7879 |
| 7883 } } // namespace v8::internal | 7880 } } // namespace v8::internal |
| OLD | NEW |