This is the mail archive of the kawa@sourceware.org mailing list for the Kawa project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

R7RS Libraries and Java interaction


Hi,

Is it possible to make an R7RS library recognise Java interaction when compiled?

e.g. if I try compiling the following:

(define-library (java)
                (export get-num)
                (import (scheme base))

                (begin
                  (define (get-num) ((String "hello"):length))
                ))

$ kawa --r7rs -C java.sld(compiling java.sld to java)
java.sld:7:54: warning - no declaration seen for :length

$ kawa --r7rs try-java.sps java.sld:7:54: unbound location: :length
    at gnu.mapping.SharedLocation.get(SharedLocation.java:22)
    at gnu.mapping.DynamicLocation.get(DynamicLocation.java:28)
    at java.getNum(java.sld:7)

If I rewrite get-num to use invoke, I still get compilation warnings, but it works at runtime.


If the answer's no, that's ok: I think Kawa's modules will interact all right with my other code. I'm just partial to the R7RS form.

  thanks for any suggestions

       Peter.

--
Peter Lane
http://peterlane.info/scheme.html


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