This is the mail archive of the
guile@sourceware.cygnus.com
mailing list for the Guile project.
Re: tie variable
- To: guile at sourceware dot cygnus dot com
- Subject: Re: tie variable
- From: Lalo Martins <lalo at hackandroll dot org>
- Date: Tue, 14 Mar 2000 07:28:20 -0300
- References: <m3ya7lx4i5.fsf@kei.cwru.edu>
On Tue, Mar 14, 2000 at 04:52:50AM -0500, Keisuke Nishida wrote:
>
> (define user-full-name (global-variable 'user-full-name))
In the final version, you will provide a macro to do this,
won't you? Let the user think he's doing something like
(import-variable user-full-name)
> (global-ref user-full-name)
> (global-set! user-full-name value)
>
> But this is rather tedious. I'd like to write:
>
> user-full-name
> (set! user-full-name value)
One way to make set! work is with GOOPS and generics.
(define-method set! ((var <emacs-variable>) value)
(global-set! var value))
(or something, I'm too tired to check)
GOOPS can probably give some way out for getting the value too,
it's worth checking.
[]s,
|alo
+----
--
Hack and Roll ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.
http://www.webcom.com/lalo mailto:lalo@hackandroll.org
pgp key in the personal page
Debian GNU/Linux --- http://www.debian.org
Brazil of Darkness --- http://zope.gf.com.br/BroDar