A RetroSearch Logo

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

Search Query:

Showing content from http://mail.python.org/pipermail/python-dev/attachments/20101031/eb3a67ca/attachment.html below:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
  </head>
  <body text="#330033" bgcolor="#ffffff">
    On 10/31/2010 2:02 PM, Benjamin Peterson wrote:
    <blockquote
      cite="mid:AANLkTikqL612PJiAoPssfukqHGOh=FRMEK_DwSbtSEk+@mail.gmail.com"
      type="cite">
      <pre wrap="">2010/10/31 Antoine Pitrou <a moz-do-not-send="true" class="moz-txt-link-rfc2396E" href="mailto:solipsis@pitrou.net">&lt;solipsis@pitrou.net&gt;</a>:
</pre>
      <blockquote type="cite" style="color: rgb(0, 0, 0);">
        <pre wrap=""><span class="moz-txt-citetags">&gt; </span>On Sun, 31 Oct 2010 16:39:44 -0400
<span class="moz-txt-citetags">&gt; </span>Eric Smith <a moz-do-not-send="true" class="moz-txt-link-rfc2396E" href="mailto:eric@trueblade.com">&lt;eric@trueblade.com&gt;</a> wrote:
<span class="moz-txt-citetags">&gt;</span>
</pre>
        <blockquote type="cite" style="color: rgb(0, 0, 0);">
          <pre wrap=""><span class="moz-txt-citetags">&gt;&gt; </span>What are your thoughts on adding a str.format_from_mapping (or similar
<span class="moz-txt-citetags">&gt;&gt; </span>name, maybe the suggested "format_map") to 3.2? See
<span class="moz-txt-citetags">&gt;&gt; </span><a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://bugs.python.org/issue6081">http://bugs.python.org/issue6081</a> . This method would be similar to
<span class="moz-txt-citetags">&gt;&gt; </span>"%(foo)s %(bar)s" % d, where d is a dict (or rather any mapping object),
<span class="moz-txt-citetags">&gt;&gt; </span>but of course would use str.format syntax: "{foo}
<span class="moz-txt-citetags">&gt;&gt; </span>{bar}".format_from_mapping(d).
</pre>
        </blockquote>
        <pre wrap=""><span class="moz-txt-citetags">&gt;</span>
<span class="moz-txt-citetags">&gt; </span>I must be missing something, but what's the difference with
<span class="moz-txt-citetags">&gt; </span>XXX.format(**d)?
</pre>
      </blockquote>
      <pre wrap="">It allows arbitrary mappings.
</pre>
    </blockquote>
    <br>
    Other than the language moratorium, why are arbitrary mappings not
    allowed for the (**d) syntax?<br>
  </body>
</html>

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