From mboxrd@z Thu Jan 1 00:00:00 1970 From: Keisuke Nishida To: guile-emacs@sourceware.cygnus.com Subject: New internal implementation Date: Fri, 05 May 2000 06:47:00 -0000 Message-id: X-SW-Source: 2000-q2/msg00026.html Hello, I've committed the new internal of Guile Emacs which uses GOOPS. Now we have three primitive procedures: `%lisp-eval', `%lisp-apply', and `%lisp->scheme'. They work like this: (%lisp-eval '(current-buffer)) => # 40457800> (eq? (%lisp-eval '(current-buffer)) (%lisp-eval '(current-buffer))) => #t (define buffer (%lisp-eval '(current-buffer))) (define name (%lisp-apply 'buffer-name (list buffer))) name => # 403cf4b0> (%lisp->scheme name) => "*scratch*" So we are now ready to implement the new Emacs Scheme code that utilizes GOOPS: (define (buffer-string) (%lisp-eval '(buffer-string))) (define-generic substring) (define-method (substring (string ) start end) (%lisp-apply 'substring (list string start end))) (define-generic eval-string) (define-method (eval-string (string )) (eval-string (%lisp->scheme string))) (eval-string (substring (buffer-string) 0 10)) For now, the old procedures (i.e., lisp-eval, lisp-apply, etc.) still exist, so this version should not break the existing Scheme code. After rewriting the code by using the new procedures, I'll remove the old procedures. (I'll be busy for more few days, so it will be after May 10.) Some additional changes from NEWS: *** Guile Emacs turns on Guile's debugging features at startup time if the command line option --debug-init is given. *** Guile Emacs now displays an error and backtrace in the *Message* buffer in detail when error-on-debug is non-nil. *** The Lisp functions `scheme-apply' and `scmref-to-lisp' are removed. Have fun! -- Kei