Add missing ShallowClone implementation for SetType

It turns out that SetType was missing a ShallowClone implementation.
Which meant that when a SetType was cloned, a TableType was received
(which has one less member). Which resulted in invalid memory accesses
when using the clone.

Thank you valgrind :)
This commit is contained in:
Johanna Amann 2019-06-18 14:37:09 -07:00
parent 5365d60202
commit 53cde131e9
2 changed files with 15 additions and 0 deletions

View file

@ -381,6 +381,8 @@ public:
SetType(TypeList* ind, ListExpr* arg_elements);
~SetType() override;
SetType* ShallowClone() override;
ListExpr* SetElements() const { return elements; }
protected: