diff --git a/ex02/src/Array.hpp b/ex02/src/Array.hpp index 853074c..58f1b7b 100644 --- a/ex02/src/Array.hpp +++ b/ex02/src/Array.hpp @@ -24,7 +24,7 @@ class Array Array(const Array& src) { - new T[0]; + this->_arr = new T[0]; *this = src; }; @@ -42,6 +42,7 @@ class Array new T[src._size]; for (size_t i = 0; i < src._size; i++) this->_arr[i] = src._arr[i]; + return *this; }; T& operator[](unsigned int index) const