Andreas Huesgen wrote:

> In c++, it is possible to write a locking system similar to the one
> below: 
> 
> 
> void myFunction()
> {
>       # create a resource lock. Locks some resource
>       ResourceLock myLock;
> 
>       # the following line may throw an exception
>       doStuff();
> }

RIIA - Resource Initialisation is Acquisition

Python is adding an RIIA mechanism in 2.5 - look at the "with"
statement.

Tim Delaney
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to