[prev in list] [next in list] [prev in thread] [next in thread] 

List:       subversion-dev
Subject:    Re: svn commit: rev 3569 - trunk/build
From:       Greg Stein <gstein () lyra ! org>
Date:       2002-10-31 9:52:01
[Download RAW message or body]

On Tue, Oct 29, 2002 at 10:42:07PM -0600, brane@tigris.org wrote:
>...
> +++ trunk/build/getversion.py	Tue Oct 29 22:42:06 2002
> @@ -31,6 +31,7 @@
>          except:
>            continue
>          setattr(result, name, int(match.group(2)))
> +    stream.close()
>      return result

Bah. It gets closed at that 'return' statement. As soon as 'stream' goes out
of scope, the refcount hits zero, and the file is closed.

That said, I'd mark it down to personal style. I never do it because it just
adds wordiness to the code. Others may want to do it for explictness.

*shrug*

Cheers,
-g

-- 
Greg Stein, http://www.lyra.org/

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic