| ... | @@ -110,7 +110,7 @@ pub fn ArrayListAligned(comptime T: type, comptime alignment: ?u29) type { | ... | @@ -110,7 +110,7 @@ pub fn ArrayListAligned(comptime T: type, comptime alignment: ?u29) type { |
| 110 | | 110 | |
| 111 | /// Creates a copy of this ArrayList, using the same allocator. | 111 | /// Creates a copy of this ArrayList, using the same allocator. |
| 112 | pub fn clone(self: *Self) !Self { | 112 | pub fn clone(self: *Self) !Self { |
| 113 | var cloned = try ArrayList(T).initCapacity(self.allocator, self.capacity); | 113 | var cloned = try Self.initCapacity(self.allocator, self.capacity); |
| 114 | cloned.appendSliceAssumeCapacity(self.items); | 114 | cloned.appendSliceAssumeCapacity(self.items); |
| 115 | return cloned; | 115 | return cloned; |
| 116 | } | 116 | } |
| ... | @@ -498,7 +498,7 @@ pub fn ArrayListAlignedUnmanaged(comptime T: type, comptime alignment: ?u29) typ | ... | @@ -498,7 +498,7 @@ pub fn ArrayListAlignedUnmanaged(comptime T: type, comptime alignment: ?u29) typ |
| 498 | | 498 | |
| 499 | /// Creates a copy of this ArrayList. | 499 | /// Creates a copy of this ArrayList. |
| 500 | pub fn clone(self: *Self, allocator: Allocator) !Self { | 500 | pub fn clone(self: *Self, allocator: Allocator) !Self { |
| 501 | var cloned = try ArrayListUnmanaged(T).initCapacity(allocator, self.capacity); | 501 | var cloned = try Self.initCapacity(allocator, self.capacity); |
| 502 | cloned.appendSliceAssumeCapacity(self.items); | 502 | cloned.appendSliceAssumeCapacity(self.items); |
| 503 | return cloned; | 503 | return cloned; |
| 504 | } | 504 | } |