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


Groups > comp.lang.python > #95244 > unrolled thread

Re: looking for standard/builtin dict-like data object

Started byChris Angelico <rosuav@gmail.com>
First post2015-08-11 14:09 +1000
Last post2015-08-11 14:09 +1000
Articles 1 — 1 participant

Back to article view | Back to comp.lang.python

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: looking for standard/builtin dict-like data object Chris Angelico <rosuav@gmail.com> - 2015-08-11 14:09 +1000

#95244 — Re: looking for standard/builtin dict-like data object

FromChris Angelico <rosuav@gmail.com>
Date2015-08-11 14:09 +1000
SubjectRe: looking for standard/builtin dict-like data object
Message-ID<mailman.63.1439266194.3627.python-list@python.org>
On Tue, Aug 11, 2015 at 1:40 PM, Cameron Simpson <cs@zip.com.au> wrote:
> I also thought the stdlib had some kind of "namespace" class with this kind
> of API, but I can't find it now:-(

It does - types.SimpleNamespace(). It accepts keyword arguments, and
will let you create more attributes on the fly (unlike a namedtuple).

ChrisA

[toc] | [standalone]


Back to top | Article view | comp.lang.python


csiph-web