This is the mail archive of the guile-emacs@sourceware.cygnus.com mailing list for the Guile project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Lisp reference to Scheme reference


My recent macro-importing changes have caused a problem.
Previously, imported macros always put the returned value through
`lispref->scm'.  Now they make Lisp references just like imported
functions.

(define-module (emacs user)
  :use-module (emacs import)
  :use-module (emacs macro))
(begin-save-excursion 1)
     => #<procedure-with-setter>

I don't think we want a Lisp reference in this case.  The easy
fix would be to make imported macros call `lispref->scm' again,
but that might be wrong for some macros.  And it gets worse:

(define lr (object-property (begin-save-excursion 1)
                            'lisp-reference))
lr
     => #<lisp-reference>
(import-lisp-function prin1-to-string)
((prin1-to-string lr))
     => "#<scheme_reference>"

So we have a Lisp reference pointing to a Scheme reference.
I think make_lispref should return the original Scheme object
instead of making such double references.  May I change it?

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]