Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions LinkedList.h
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ class LinkedList{
public:
LinkedList();
LinkedList(int sizeIndex, T _t); //initiate list size and default value
LinkedList(const LinkedList&) = delete; // copy constructor isn't supported
virtual ~LinkedList();

/*
Expand Down Expand Up @@ -104,8 +105,8 @@ class LinkedList{
// add support to array brakets [] operator
inline T& operator[](int index);
inline T& operator[](size_t& i) { return this->get(i); }
inline const T& operator[](const size_t& i) const { return this->get(i); }

inline const T& operator[](const size_t& i) const { return this->get(i); }
LinkedList<T>& operator=(const LinkedList<T>& other) = delete; // copy operator isn't supported
};

// Initialize LinkedList with false values
Expand Down