Currently, a dictionary is used as a mutable context container. Perhaps it would make sense to replace it with something more lightweight.