[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Problems with field initialization: Proposal
Andre van Tonder <andre@xxxxxxxxxxxxxxxxxxx> writes:
> (define-type rational (x y)
> (let ((common (gcd x y)))
> (field-values
> (num (/ x common))
> (denom (/ y common))))
> (fields (num (rational-num))
> (denom (rational-denom))))
Could you elaborate on how the general mechanism would work? I.e. is
there a special syntax for the (let ...) stuff, or is it general
Scheme, with FIELD-VALUES being a special form?
--
Cheers =8-} Mike
Friede, Völkerverständigung und überhaupt blabla