A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2004-October/049464.html below:

[Python-Dev] ConfigParser shootout, preliminary entry

[Python-Dev] ConfigParser shootout, preliminary entryBob Ippolito bob at redivi.com
Mon Oct 18 19:57:31 CEST 2004
On Oct 18, 2004, at 13:46, Josiah Carlson wrote:

>> Attributes may be 'generic' (untyped) or 'typed', and are stored in
>> the order they are declared in the class statement. The value provided
>> in the definition above is the 'default value'. Simple attributes may
>> also be provided, but won't be type checked or kept in the original
>> order. To read the ini file, just do this:
>
> I think the syntax looks good, but as per a thread in python-list, you
> cannot discover the order of class variables by any solution (metaclass
> or otherwise), due to the fact that they become part of the class
> dictionary; which is arbitrarily unordered.
>
> If ordering is important to a user, one could have an optional 
> __order__
> attribute that gives the list of items in-order.

That's not quite true.  TypedAttribute instances and iniSection's 
__new__ could have serial numbers.

-bob

More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4