[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
From: Tom Shultz, Dept. of Psychology, McGill Univ.
Subject: data structures <--> functions
Comments: To: Jonathan A Rees <JAR@mc.lcs.mit.edu>
Comments: cc: firstname.lastname@example.org
In-Reply-To: <Msg of 3 Dec 87 17:12>
>>>Try something like
>>> (define evaluate
>>> (lambda (expression)
>>> (call-with-output-file "temp"
>>> (lambda (port)
>>> (write `(define temp ,expression) port)))
>>> (load "temp")
>>>if you can manage to do so without making yourself ill.
One of the problems with this approach is that both "load"
and "eval" are supposed to be avoided by MacScheme users
wanting to take advantage of selective linking. Another problem
is the slowness of accessing an external file.
There really should be a better solution for this general problem
of having a program build a data structure and then execute it as