Re: sharing vars with different functions

2007-10-29 Thread Bruno Desthuilliers
[EMAIL PROTECTED] a écrit : > Im tryin to call s/call/access/ > a var thats sitting s/sitting/defined/ > in a function, example: In this example, s/function/class/ > class someclass(object): pep08 : should be SomeClass(object): > somevar = open(blah, 'r').readlines() Doing IO in

Re: sharing vars with different functions

2007-10-29 Thread Martin Marcher
I hate gmail, always forgetting to set the right recipient... -- Forwarded message -- From: Martin Marcher <[EMAIL PROTECTED]> Date: 29.10.2007 10:11 Subject: Re: sharing vars with different functions To: "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> 2007/1

Re: sharing vars with different functions

2007-10-29 Thread Marc 'BlackJack' Rintsch
On Mon, 29 Oct 2007 09:03:14 +, [EMAIL PROTECTED] wrote: > Im tryin to call a var thats sitting in a function, example: > > class someclass(object): > somevar = open(blah, 'r').readlines() Thats a class variable. Is that really what you want!? > def something(): > > for l

sharing vars with different functions

2007-10-29 Thread [EMAIL PROTECTED]
Im tryin to call a var thats sitting in a function, example: class someclass(object): somevar = open(blah, 'r').readlines() def something(): for line in somevar: print line --- i guess im not gra