You could define a 'hook' the way emacs and guile do.
;wrapper.scm (define disp-hook (list (lambda () (void))))
(define (add-hook hook thunk) (set-cdr! hook (cons thunk '())))
(define (run-hook hook) (for-each (lambda (p) (p)) hook))
(c-define (c-disp) () void "f" "" (run-hook disp-hook))
;test.scm (load "graphics")
(define (disp) (glClear GL_COLOR_BUFFER_BIT) (glutWireTeapot 0.5))
(add-hook disp-hook disp)
On Mon, Jan 19, 2009 at 5:43 PM, symbolic expression symbolic.expression@gmail.com wrote:
so the question is ... how can i get compile scheme code to 'wait' in order to call interpted scheme code?
thanks!