GLITCH
GLITCH copied to clipboard
change attributes of UnitBlock to be more object-oriented
Describe the solution you'd like
Right now, the UnitBlock has an attribute for each type of element. However, this does not scale well, does not adhere to good practices of object-oriented programming and it is not intuitive when generic statements are in the mix. For instance, let's imagine a conditional statement has a atomic unit in its blocks. Should the atomic unit also be added to the atomic_units attribute? It doesn't make sense.
Describe alternatives you've considered The UnitBlock should have a single attribute for statements.