Re: Interest check in some delicious syntactic sugar for "except:pass"

2010-03-04 Thread Bruno Desthuilliers
Oren Elrad a écrit : Howdy all, longtime appreciative user, first time mailer-inner. I'm wondering if there is any support (tepid better than none) for the following syntactic sugar: silence: block -> try: block except: pass Hopefully not.

Re: Interest check in some delicious syntactic sugar for "except:pass"

2010-03-03 Thread Rhodri James
On Wed, 03 Mar 2010 09:27:16 -, Oren Elrad wrote: Howdy all, longtime appreciative user, first time mailer-inner. I'm wondering if there is any support (tepid better than none) for the following syntactic sugar: silence: block -> try: block except: .

Re: Re Interest check in some delicious syntactic sugar for "except:pass"

2010-03-03 Thread Terry Reedy
On 3/3/2010 6:47 AM, Oren Elrad wrote: With that said, let me at least offer a token defense of my position. By way of motivation, I wrote that email after copying/pasting the following a few times around a project until I wrote it into def SilentlyDelete() and its cousin SilentlyRmdir() """ co

Re: Re Interest check in some delicious syntactic sugar for "except:pass"

2010-03-03 Thread Steven D'Aprano
On Wed, 03 Mar 2010 06:47:28 -0500, Oren Elrad wrote: > With that said, let me at least offer a token defense of my position. By > way of motivation, I wrote that email after copying/pasting the > following a few times around a project until I wrote it into def > SilentlyDelete() and its cousin Si

Re: Re Interest check in some delicious syntactic sugar for "except:pass"

2010-03-03 Thread Mel
Tim Chase wrote: > I admit there are times I've done something similar, usually with > what I call my "int0" and "float0" utility functions which > roughly translate to "give me a stinkin' int/float and if > something goes wrong, give me 0, but the return result better > darn well be an int/float!"

Re: Interest check in some delicious syntactic sugar for "except:pass"

2010-03-03 Thread MRAB
Oren Elrad wrote: Howdy all, longtime appreciative user, first time mailer-inner. I'm wondering if there is any support (tepid better than none) for the following syntactic sugar: silence: block -> try: block except: pass The logic here is tha

Re: Re Interest check in some delicious syntactic sugar for "except:pass"

2010-03-03 Thread Michael Rudolf
Am 03.03.2010 12:47, schrieb Oren Elrad: """ code involving somefile """ try: os.remove(somefile) except: ...pass # The bloody search indexer has got the file and I can't delete it. Nothing to be done. You don't know that what you stated in your comment is true. All you know is

Re: Re Interest check in some delicious syntactic sugar for "except:pass"

2010-03-03 Thread Tim Chase
Oren Elrad wrote: """ code involving somefile """ try: os.remove(somefile) except: ...pass # The bloody search indexer has got the file and I can't delete it. Nothing to be done. I admit there are times I've done something similar, usually with what I call my "int0" and "float

Re: Re Interest check in some delicious syntactic sugar for "except:pass"

2010-03-03 Thread Daniel Fetchinson
> By way of motivation, I wrote that email after copying/pasting the > following a few times around a project until I wrote it into def > SilentlyDelete() and its cousin SilentlyRmdir() > > """ code involving somefile """ > try: > os.remove(somefile) > except: > ...pass # The bloody

Re: Re Interest check in some delicious syntactic sugar for "except:pass"

2010-03-03 Thread Benjamin Kaplan
On Wed, Mar 3, 2010 at 6:47 AM, Oren Elrad wrote: > To all that responded, thanks for the prompt response folks, your > criticisms are well taken. Coming from Cland, one is inculcated with > the notion that if the programmer wants to shoot himself in the foot > the language ought not to prevent t

Re: Interest check in some delicious syntactic sugar for "except:pass"

2010-03-03 Thread Tim Chase
Oren Elrad wrote: I'm wondering if there is any support (tepid better than none) for the following syntactic sugar: silence: block -> try: block except: pass The general response to "except: pass" from the Old Ones on the python list (and tho

Re Interest check in some delicious syntactic sugar for "except:pass"

2010-03-03 Thread Oren Elrad
To all that responded, thanks for the prompt response folks, your criticisms are well taken. Coming from Cland, one is inculcated with the notion that if the programmer wants to shoot himself in the foot the language ought not to prevent that (or even should return him a loaded magnum with the safe

Re: Interest check in some delicious syntactic sugar for "except:pass"

2010-03-03 Thread Andre Engels
On Wed, Mar 3, 2010 at 10:27 AM, Oren Elrad wrote: > Howdy all, longtime appreciative user, first time mailer-inner. > > I'm wondering if there is any support (tepid better than none) for the > following syntactic sugar: > > silence: > block > > -> > > try: > .

Re: Interest check in some delicious syntactic sugar for "except:pass"

2010-03-03 Thread Dave Angel
Oren Elrad wrote: Howdy all, longtime appreciative user, first time mailer-inner. I'm wondering if there is any support (tepid better than none) for the following syntactic sugar: silence: block -> try: block except: pass The logic here is tha

Re: Interest check in some delicious syntactic sugar for "except:pass"

2010-03-03 Thread Chris Rebert
On Wed, Mar 3, 2010 at 1:27 AM, Oren Elrad wrote: > Howdy all, longtime appreciative user, first time mailer-inner. > > I'm wondering if there is any support (tepid better than none) for the > following syntactic sugar: > > silence: > block > > -> > > try: > ..