Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #95911

Re: Python handles globals badly.

From Mark Lawrence <breamoreboy@yahoo.co.uk>
Subject Re: Python handles globals badly.
Date 2015-09-03 02:10 +0100
References <c3363$547e74fe$5419aafe$24179@news.ziggo.nl> <253e3584-1d4d-4e6f-b42f-2cdbfa4ad785@googlegroups.com> <CALwzidn4iGZNE1u=G++-eKkG5jdN-oXPzrLpuED3xO_EN-Z02w@mail.gmail.com> <CAK_ErkgaGE4C8t4LYYO3N9JEqLmN1=mb=jegX255iQ32-qHzSQ@mail.gmail.com>
Newsgroups comp.lang.python
Message-ID <mailman.47.1441242669.8327.python-list@python.org> (permalink)

Show all headers | View raw


On 03/09/2015 01:16, Vladimir Ignatov wrote:
> Hi,
>
> my 0.02
>
> I don't personally use globals. And don't like "object oriented" code
> (my code more inclined toward "functional" style). But sometimes I
> feel like passing various minor values (like settings) all around app
> via regular parameters is just too much work.  So I use
> "pseudo-global" object which holds various stuff in its attributes.
> And I pass that object around my code. But that is just one parameter,
> not myriads of them.
>
> Vladimir
>
> http://itunes.apple.com/us/app/python-code-samples/id1025613117
>

Conceptually something like this 
https://code.activestate.com/recipes/52308-the-simple-but-handy-collector-of-a-bunch-of-named 
?

-- 
My fellow Pythonistas, ask not what our language can do for you, ask
what you can do for our language.

Mark Lawrence

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Re: Python handles globals badly. tdev@freenet.de - 2015-09-02 15:25 -0700
  Re: Python handles globals badly. Ian Kelly <ian.g.kelly@gmail.com> - 2015-09-02 16:57 -0600
  Re: Python handles globals badly. Vladimir Ignatov <kmisoft@gmail.com> - 2015-09-02 20:16 -0400
  Re: Python handles globals badly. Mark Lawrence <breamoreboy@yahoo.co.uk> - 2015-09-03 02:10 +0100
  Re: Python handles globals badly. Mark Lawrence <breamoreboy@yahoo.co.uk> - 2015-09-03 02:15 +0100
  Re: Python handles globals badly. "Sven R. Kunze" <srkunze@mail.de> - 2015-09-04 01:06 +0200

csiph-web