Reviewers: rossberg,

Description:
Fix template copy constructor in zone_allocator

[email protected]

Please review this at https://codereview.chromium.org/165943005/

SVN Base: https://v8.googlecode.com/svn/branches/bleeding_edge

Affected files (+4, -1 lines):
  M src/zone-allocator.h


Index: src/zone-allocator.h
diff --git a/src/zone-allocator.h b/src/zone-allocator.h
index 5245c6b1bfd45d3d23e5e5efb82a5b4fa4707fba..0ede5e041cdb1a73dd3f37f2440d0f1540a24904 100644
--- a/src/zone-allocator.h
+++ b/src/zone-allocator.h
@@ -50,7 +50,9 @@ class zone_allocator {
   explicit zone_allocator(Zone* zone) throw() : zone_(zone) {}
   explicit zone_allocator(const zone_allocator& other) throw()
       : zone_(other.zone_) {}
-  template<typename U> zone_allocator(const zone_allocator<U>&) throw() {}
+ template<typename U> zone_allocator(const zone_allocator<U>& other) throw()
+      : zone_(other.zone_) {}
+  template<typename U> friend class zone_allocator;

   pointer address(reference x) const {return &x;}
   const_pointer address(const_reference x) const {return &x;}
@@ -72,6 +74,7 @@ class zone_allocator {
   void destroy(pointer p) { (static_cast<T*>(p))->~T(); }

  private:
+  zone_allocator();
   Zone* zone_;
 };



--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
--- You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to