chicken-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Chicken-users] Recursive Types?


From: Martin Schneeweis
Subject: Re: [Chicken-users] Recursive Types?
Date: Sat, 23 Jun 2018 02:27:06 +0200

Hi,

>   (define my-fun (lambda (lst) ...))
> 
> and I want to make sure that every odd element is a symbol and every
> even element is a string.

the best I could come up with is

  (: my-fun ((list-of (pair symbol string)) --> string))
  (define my-fun (lambda (lst) ...))

Unfortunately a little bit unwieldy on the client side

  (my-fun '((a . "a")(b . "b") ... )))

Martin



reply via email to

[Prev in Thread] Current Thread [Next in Thread]