Contexts are created and used to manage the execution
environment. They provide a convenient location for
storing globals organized by the module using the
globals.
We provide this abstract class for other implementations
to use so that they can simply add fields and operations on
them. To be usable by the context manager, the subclasses
must define CleanupOnError and call super() in any constructor.
Contexts assist in cleanup
when errors are caught in the outer block.
Contexts implement the sanity interface to check and provide
information about their contents.
|