On Tue, Sep 16, 2008 at 5:44 AM, Alberto Ganesh Barbati <
[email protected]> wrote:

> Richard Tew ha scritto:
> > On Sat, Sep 13, 2008 at 2:15 PM, Nicolas Stein <[email protected]>
> wrote:
> >> Am I right in assuming that, if I never use preemptive scheduling, I
> >> never need to use "...set_atomic(True)...",
> >> to guarantee the atomicity of the middle block ?
> >
> > Yes.
> >
>
> By the way, will stackless provide context manager for atomicity to be
> used in the "with" statement? I mean, wouldn't it be good to be able to
> write:
>
>  with stackless.atomic():
>    your_code_here()
>
> ....

Same thing, possibly, for set_ignore_nesting().
>
>
Just over two years later, but I would like to note that you can now do this
using Kristjan Valur's stacklesslib.

See:


http://code.google.com/p/stacklessexamples/source/browse/trunk/libraries/stacklesslib/util.py

<http://code.google.com/p/stacklessexamples/source/browse/trunk/libraries/stacklesslib/util.py>
Cheers,
Richard.
_______________________________________________
Stackless mailing list
[email protected]
http://www.stackless.com/mailman/listinfo/stackless

Reply via email to