| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 63ed0b8 commit 290f2d8
2 files changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -36,7 +36,7 @@ | |||
| 36 | 36 | ||
| 37 | 37 | # Reset this number to 0 on major V8 upgrades. | |
| 38 | 38 | # Increment by one for each non-official patch applied to deps/v8. | |
| 39 | - 'v8_embedder_string': '-node.10', | ||
| 39 | + 'v8_embedder_string': '-node.11', | ||
| 40 | 40 | ||
| 41 | 41 | ##### V8 defaults for Node.js ##### | |
| 42 | 42 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -2649,10 +2649,7 @@ class StrongRootBlockAllocator { | |||
| 2649 | 2649 | using size_type = size_t; | |
| 2650 | 2650 | using difference_type = ptrdiff_t; | |
| 2651 | 2651 | template <class U> | |
| 2652 | - struct rebind { | ||
| 2653 | - STATIC_ASSERT((std::is_same<Address, U>::value)); | ||
| 2654 | - using other = StrongRootBlockAllocator; | ||
| 2655 | - }; | ||
| 2652 | + struct rebind; | ||
| 2656 | 2653 | ||
| 2657 | 2654 | explicit StrongRootBlockAllocator(Heap* heap) : heap_(heap) {} | |
| 2658 | 2655 | ||
@@ -2663,6 +2660,23 @@ class StrongRootBlockAllocator { | |||
| 2663 | 2660 | Heap* heap_; | |
| 2664 | 2661 | }; | |
| 2665 | 2662 | ||
| 2663 | + // Rebinding to Address gives another StrongRootBlockAllocator. | ||
| 2664 | + template <> | ||
| 2665 | + struct StrongRootBlockAllocator::rebind<Address> { | ||
| 2666 | + using other = StrongRootBlockAllocator; | ||
| 2667 | + }; | ||
| 2668 | + | ||
| 2669 | + // Rebinding to something other than Address gives a std::allocator that | ||
| 2670 | + // is copy-constructable from StrongRootBlockAllocator. | ||
| 2671 | + template <class U> | ||
| 2672 | + struct StrongRootBlockAllocator::rebind { | ||
| 2673 | + class other : public std::allocator<U> { | ||
| 2674 | + public: | ||
| 2675 | + // NOLINTNEXTLINE | ||
| 2676 | + other(const StrongRootBlockAllocator&) {} | ||
| 2677 | + }; | ||
| 2678 | + }; | ||
| 2679 | + | ||
| 2666 | 2680 | } // namespace internal | |
| 2667 | 2681 | } // namespace v8 | |
| 2668 | 2682 | ||
| Back | FazBrowse Home | New Git URL |
0 commit comments