Add "StackLike" interface, which is implemented by structs to represent a part of the parsing state.