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/2002-June/025608.html below:

[Python-Dev] PEP 292, Simpler String Substitutions

[Python-Dev] PEP 292, Simpler String Substitutions [Python-Dev] PEP 292, Simpler String SubstitutionsPaul Prescod paul@prescod.net
Wed, 19 Jun 2002 09:43:02 -0700
Guido van Rossum wrote:
> 
>...
> 
> I'm strongly in favor of always making missing keys an error.  It
> should be a KeyError when a dict is used, and a NameError when
> locals/globals are looked up.

I think someone later suggested that maybe a keyword argument could
allow some kind of policy to be expressed. That would be okay for me if
people feel strongly that some strategy for fixing up missing arguments
is necessary.

> > Overall it isn't bad...it's a little weird to have a method that depends
> > on sys._getframe(1) (or as the say in Tcl-land "upvar"). It may set a
> > bad precedent...
> 
> No, the real implementation will be in C.  C functions always have
> access to locals and globals.

I didn't mean it will be a bad precedent because of the implemention. I
mean that methods do not usually peak into their caller's variables,
even from C. What other methods do that? I'm still "+0" despite being
somewhat uncomfortable with that aspect.

 Paul Prescod




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