Spinroot

A forum for Spin users

You are not logged in.

#1 2012-11-12 10:50:34

maryam
Member
Registered: 2012-03-27
Posts: 16

variable's value in the previous state

I was wondering if there is a ready function to get the value of a variable in the previous state? Or just a prefix (e.g. 'pre') or somewhat like 'now'?

Offline

#2 2012-11-12 20:21:47

spinroot
forum
Registered: 2010-11-18
Posts: 695
Website

Re: variable's value in the previous state

there's no predefined function to do so -- you can of course add
a ghost variable yourself, to remember the previous value...

atomic { a_prime = a; a = newvalue };

Offline

#3 2012-11-13 05:53:11

maryam
Member
Registered: 2012-03-27
Posts: 16

Re: variable's value in the previous state

thanks for reply.

Offline

Board footer

Powered by FluxBB