Skip to content

Commit

Permalink
Merge pull request #13 from simonrenger/master
Browse files Browse the repository at this point in the history
Updated to modern c++
  • Loading branch information
mtrebi authored Apr 3, 2019
2 parents 706352b + d732e20 commit 9f25a0f
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 10 deletions.
2 changes: 1 addition & 1 deletion includes/PoolAllocator.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ class PoolAllocator : public Allocator {
private:
struct FreeHeader{
};
typedef StackLinkedList<FreeHeader>::Node Node;
using Node = StackLinkedList<FreeHeader>::Node;
StackLinkedList<FreeHeader> m_freeList;

void * m_start_ptr = nullptr;
Expand Down
6 changes: 2 additions & 4 deletions includes/StackLinkedList.h
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,10 @@ class StackLinkedList {

Node* head;
public:
StackLinkedList();

StackLinkedList() = default;
StackLinkedList(StackLinkedList &stackLinkedList) = delete;
void push(Node * newNode);
Node* pop();
private:
StackLinkedList(StackLinkedList &stackLinkedList);
};

#include "StackLinkedListImpl.h"
Expand Down
5 changes: 0 additions & 5 deletions includes/StackLinkedListImpl.h
Original file line number Diff line number Diff line change
@@ -1,10 +1,5 @@
#include "StackLinkedList.h"

template <class T>
StackLinkedList<T>::StackLinkedList() {

}

template <class T>
void StackLinkedList<T>::push(Node * newNode) {
newNode->next = head;
Expand Down

0 comments on commit 9f25a0f

Please sign in to comment.