diff --git a/Nodes.hpp b/Nodes.hpp index e002998..1260d37 100644 --- a/Nodes.hpp +++ b/Nodes.hpp @@ -41,9 +41,9 @@ public: template -class List: public std::vector { +class PointerList: public std::vector { public: - virtual ~List() { + virtual ~PointerList() { for (T *element: *this) { delete element; } @@ -51,14 +51,14 @@ public: }; -class StatementList: public List, public Emittable { +class StatementList: public PointerList, public Emittable { public: virtual void emit(std::ostream &stream, int indent = 0); }; template -class ListEmittable: public List, public Emittable { +class ListEmittable: public PointerList, public Emittable { public: virtual void emit(std::ostream &stream, int indent = 0) { if (this->size() > 0) { @@ -234,7 +234,7 @@ private: }; -typedef List BranchCaseList; +typedef PointerList BranchCaseList; class Branch: public Statement { @@ -288,7 +288,7 @@ public: private: std::unique_ptr
main; - List functions; + PointerList functions; };