[Date Prev][Date Next][Subject Prev][Subject Next][ Date Index][ Subject Index]

Re: NR (no ruler)



Reply to note from "Patricia M. Godfrey"  Wed,
30 Jan 2008 09:52:10 -0500

> the general technique is applicable to any situation where one
> wants to set a state regardless of the current state.

Yes -- although one doesn't usually have at one's disposal a
function, like NR, that cycles through all the possible states.
More commonly, you simply force the desired state, n, with
D[EFAULT] xx=n, after saving the existing state, v, to a S/G so that
it can be restored later. So, the more common general technique is:

;*; Initialize S/G 01 (the "null routine")
<>n>;*; If current default xx <> n
>;*; Save current value, v, to S/G 01
+"Q2 ">;*; Manufacture routine 01 to restore
original value (currently in S/G 01)
BX d xx=nQ2 ;*; Set default xx to n
;*; EndIf

Later, you restore the original value with , which executes
the manufactured routine "BX d xx=vQ2 " (or the null routine, if the
original value was n to begin with). Q.E.D.

--
Carl Distefano
cld@xxxxxxxx