Core/Composite: Simplify Composite.context
chr5tphr opened this issue · 0 comments
chr5tphr commented
Composite.context
can be implemented slimmer/simpler using contextlib.contextmanager
.
Furthermore, instead of calling Composite.context
, the same functionality could be implemented as Composite.__call__
, as the context is the main functionality, and this would remove a little bit of overhead, although .context
may be more descriptive.