KAWA: keyword and apply

Chris Dean ctdean@mercedsystems.com
Thu Jan 30 20:07:00 GMT 2003


Works for me on a fairly recent CVS version.  What version of kawa are
you running?

    (define (proc #!key foo bar)
      (format #t "foo is ~A~%" foo)
      (format #t "bar is ~A~%" bar))

    #|kawa:192|# (apply proc '(foo: "foo-string" bar: 123))
    foo is foo-string
    bar is 123


Regards,
Chris Dean

Wen-Chun Ni <wcn@tbcommerce.com> wrote:
> Hi,
> 
> If I have
> 
>   (define (proc #!key foo bar) ...)
> 
> can I do something like
> 
>   (apply proc '(foo: "foo-string" bar: 123))  ?
> 
> I tried and failed (got all #f instead). Or is it the wrong thing to do?
> 
> Thanks!
> 
> 
> Wen-Chun Ni



More information about the Kawa mailing list