GSOC | Extending Common Lisp support

Charles Turner chturne@gmail.com
Thu Apr 26 22:18:00 GMT 2012


Thanks for the explanation Jamison. I haven't incorporated your latest
suggestions, but I attach my most recent work on the scoping, most of
the scoping scenarios I could think of have seem to work.

One thing I noticed today which didn't make much sense to me was the following:

(define (test)
  (let ((x :: integer 10.5))
    (* x x)))
/dev/stdin:2:23: warning - type DFloNum is incompatible with required
type integer
/dev/stdin:3:5: warning - cannot convert literal (of type
gnu.math.DFloNum) to Type integer

So far, as expected. But when you type (test), you get:

Value '110.25' has wrong type (DFloNum) (expected: integer)

Note that is the result of (* x x), not the initial static type. What
good is that if you're wanting static type safety? I note that the
warnings at least point to the cause in the case of a disaster, but is
this something that could be more strongly typed?

Thanks,
Charlie.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: declare.diff
Type: application/octet-stream
Size: 7322 bytes
Desc: not available
URL: <http://sourceware.org/pipermail/kawa/attachments/20120426/5aa771a1/attachment.obj>


More information about the Kawa mailing list