On Fri, Mar 11, 2005 at 06:47:11PM -0500, Bob Ippolito wrote:
> 
> On Mar 11, 2005, at 2:26 PM, Skip Montanaro wrote:
> 
> >
> >    Bob> try:
> >    Bob>      set
> >    Bob> except NameError:
> >    Bob>      from sets import Set as set
> >
> >    Bob> You don't need the rest.
> >
> >Sure, but then pychecker bitches about a statement that appears to 
> >have no
> >effect. ;-)
> 
> Well then fix PyChecker to look for this pattern :)
> 
> -bob

or make it even uglier to hide from pychecker by writing that as:

exec("""
try:
    set
except NameError:
    from sets import Set as set
""")

_______________________________________________
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Reply via email to