[DGD] rlimits
Felix A. Croes
felix at dworkin.nl
Mon Mar 29 22:39:03 CEST 2004
Steve Wooster <swooster at xprt.net> wrote:
> Could that allow code to do something like this without running out of
> ticks? (assume depth comes first, ticks comes second in the argument list)
The syntax is: rlimits (depth; ticks) { ... }
> void func()
> {
> // Assume I have 100 ticks remaining.
> // Assume rlimits uses 5 ticks.
> rlimits (0,95)
> {
> Code that takes up 90 ticks;
> }
> rlimits (0,90)
> {
> Code that takes up 85 ticks;
> }
> // Are there still about 90 ticks left despite having
> // executed 175 ticks worth of code?
> }
Yes.
Regards,
Dworkin
_________________________________________________________________
List config page: http://list.imaginary.com/mailman/listinfo/dgd
More information about the DGD
mailing list