[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

C*R improvement



While CADADDAADDDAAADDDR is sexy, it really doesn't go far enough.  Much
better would be to allow numbers in among the A's and D's, which would serve
as multipliers for the following letters.  For instance C3A2DAR would
be equivalent to CAAADDAR.  Of course, we'd have to be careful about radix
issues -- better expand this at readtime and look at IBASE then.  Better still
we could have some sort of escape convention (for now I will call it #?) that
lets you insert a variable whose current value (an integer or a string of
C's and D's is inserted at that point).  So

(setq foo 4)
(cad#?fooadr x)

is eqivalent to (cad4adr x) ==> (cadaaaadr x).  This clearly wants to
expand at runtime so that the value of foo can be changed to get
different effects.

One could evan imagine allowing the user to insert arbitrary Lisp expressions
in to C*R form, but in my opinion this would be confusing and not very
useful.

Cheers,
Scott