<br><br><div class="gmail_quote">On 25 July 2011 21:33, Robert Kern <span dir="ltr"><<a href="mailto:robert.kern@gmail.com">robert.kern@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<div class="im">On 7/25/11 2:09 PM, Michael Foord wrote:<br>
</div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="im">
<br>
<br>
On 25 July 2011 19:47, Raymond Hettinger<br>
<<a href="mailto:raymond.hettinger@gmail.com" target="_blank">raymond.hettinger@gmail.com</a><br></div><div class="im">
<mailto:<a href="mailto:raymond.hettinger@gmail.com" target="_blank">raymond.hettinger@<u></u>gmail.com</a>>> wrote:<br>
<br>
<br>
    On Jul 25, 2011, at 1:06 PM, Michael Foord wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
    Python standard library modules currently using integers for constants:<br>
<br>
    * re - has flags (OR'able constants) defined in sre_constants, each flag<br>
    has two names (e.g. re.IGNORECASE and re.I)<br>
</blockquote>
<br>
    What is being proposed here?  Will there be a new namespace so that we would<br>
    start writing re.Flags.IGNORECASE instead of re.IGNORECASE?  Are module<br>
    level constants now going to be considered bad-form?<br>
<br>
    If constants switch from re.IGNORECASE to re.flags.IGNORECASE, are there any<br>
    benefits to compensate for being both wordier and slower?<br>
<br>
<br>
Nope. Just something like this at the module level.<br>
<br>
IGNORECASE = Flags.IGNORECASE<br>
<br>
What it gains you is a nicer representation when looking at the values when<br>
debugging.<br>
</div></blockquote>
<br>
+1. It's not a problem I run into every time I debug something, but it happens often enough that the feeling of frustration is quite familiar each time it crops up. It's like an old college acquaintance that shows up to crash "just a few nights" on your couch every time he's in town.<br>
<font color="#888888">
<br>
-- <br>
Robert Kern<br>
<br>
"I have come to believe that the whole world is an enigma, a harmless enigma<br>
 that is made terrible by our own mad attempt to interpret it as though it had<br>
 an underlying truth."<br>
  -- Umberto Eco</font><div><div></div><div class="h5"><br>
<br>
______________________________<u></u>_________________<br>
Python-ideas mailing list<br>
<a href="mailto:Python-ideas@python.org" target="_blank">Python-ideas@python.org</a><br>
<a href="http://mail.python.org/mailman/listinfo/python-ideas" target="_blank">http://mail.python.org/<u></u>mailman/listinfo/python-ideas</a><br>
</div></div></blockquote></div><br><br clear="all"><br>-- <br><pre cols="72"><a href="http://www.voidspace.org.uk/" target="_blank">http://www.voidspace.org.uk/</a><br><br>May you do good and not evil<br>May you find forgiveness for yourself and forgive others<br>
May you share freely, never taking more than you give.<br>-- the sqlite blessing <a href="http://www.sqlite.org/different.html" target="_blank">http://www.sqlite.org/different.html</a></pre>
<br>