Re: namespaces and eval

2008-05-20 Thread George Sakkis
On May 16, 5:02 pm, Arnaud Delobelle <[EMAIL PROTECTED]> wrote: > [EMAIL PROTECTED] writes: > > Sorry for the repost, didnt' quite finish > > > Suppose I have a function in module X that calls eval e.g, > > > X.py > > ___ > > Def foo(bar): > >         Eval(bar) > > ___ > > > Now eval will b

Re: namespaces and eval

2008-05-20 Thread dave
On May 17, 12:20 am, Arnaud Delobelle <[EMAIL PROTECTED]> wrote: > [EMAIL PROTECTED] writes: > > On May 16, 2:47 pm, "[EMAIL PROTECTED]" > > <[EMAIL PROTECTED]> wrote: > >> On 16 mai, 23:23, [EMAIL PROTECTED] wrote: > > >> > Thanks for the responses. I'm well aware that the function can be > >> >

Re: namespaces and eval

2008-05-17 Thread Arnaud Delobelle
[EMAIL PROTECTED] writes: > On May 16, 2:47 pm, "[EMAIL PROTECTED]" > <[EMAIL PROTECTED]> wrote: >> On 16 mai, 23:23, [EMAIL PROTECTED] wrote: >> >> > Thanks for the responses. I'm well aware that the function can be >> > passed in the parameters, passing in the functino as an arg defeats >> > th

Re: namespaces and eval

2008-05-16 Thread dave . g1234
On May 16, 2:47 pm, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > On 16 mai, 23:23, [EMAIL PROTECTED] wrote: > > > Thanks for the responses. I'm well aware that the function can be > > passed in the parameters, passing in the functino as an arg defeats > > the purpose of what I'm going after. >

Re: namespaces and eval

2008-05-16 Thread [EMAIL PROTECTED]
On 16 mai, 23:23, [EMAIL PROTECTED] wrote: > Thanks for the responses. I'm well aware that the function can be > passed in the parameters, passing in the functino as an arg defeats > the purpose of what I'm going after. Why so ? > @ Arnaud - Nice. I'm not sure what the performance of mine vs. yo

Re: namespaces and eval

2008-05-16 Thread dave . g1234
Thanks for the responses. I'm well aware that the function can be passed in the parameters, passing in the functino as an arg defeats the purpose of what I'm going after. @ Arnaud - Nice. I'm not sure what the performance of mine vs. yours, but a perfunctory glance looks like we're doing the clos

Re: namespaces and eval

2008-05-16 Thread [EMAIL PROTECTED]
On 16 mai, 20:44, [EMAIL PROTECTED] wrote: > Suppose I have a function in module X that calls eval e.g, > > X.py > ___ > Def foo(bar): > Eval(bar) > ___ > > Now eval will be called using the default eval(bar,globals(),locals()) > and globals will pull in anything in module X. > > No

Re: namespaces and eval

2008-05-16 Thread Arnaud Delobelle
[EMAIL PROTECTED] writes: > Sorry for the repost, didnt' quite finish > > Suppose I have a function in module X that calls eval e.g, > > X.py > ___ > Def foo(bar): > Eval(bar) > ___ > > Now eval will be called using the default eval(bar,globals(),locals()) > and globals will pull i

namespaces and eval

2008-05-16 Thread dave . g1234
Sorry for the repost, didnt' quite finish Suppose I have a function in module X that calls eval e.g, X.py ___ Def foo(bar): Eval(bar) ___ Now eval will be called using the default eval(bar,globals(),locals()) and globals will pull in anything in module X. Now I have module Y tha

namespaces and eval

2008-05-16 Thread dave . g1234
Suppose I have a function in module X that calls eval e.g, X.py ___ Def foo(bar): Eval(bar) ___ Now eval will be called using the default eval(bar,globals(),locals()) and globals will pull in anything in module X. Now I have module Y that calls bar like so Y.py from x im