Layers of abstraction, was Re: RFC: Proposal: Deterministic Object Destruction

Ooomzay ooomzay at gmail.com
Wed Mar 7 01:42:56 EST 2018


On Tuesday, 6 March 2018 14:12:38 UTC, Peter Otten wrote:
> Chris Angelico wrote:
>> > On Tue, Mar 6, 2018 at 10:04 AM, Steven D'Aprano
> > <steve+comp.lang.python at pearwood.info> wrote:
> >> # Later.
> >> if __name__ = '__main__':
> >> # Enter the Kingdom of Nouns.
> > 
> > Don't you need a NounKingdomEnterer to do that for you?
>> No, for some extra flexibility there should be a NounKingdomEntererFactory 

For example open().
> -- which of course has to implement the AbstractNounKingdomEntererFactory 
> interface. 

For example a PEP 343 "Context Manager".
In the swamplands of the pythonistas the one-eyed man is BDFL!
Amen.


More information about the Python-list mailing list

AltStyle によって変換されたページ (->オリジナル) /