I’ve been trying to figure out the syntax for optional keywords in the ->i 
contract form. For example:

(->i ([lst list?])
       ([#:foo ….]) ; what does this look like? 
       (result list?))

The mandatory domain syntax seems straightforward, but I’ve tried various 
combinations for the optional keyword that don’t appear to be correct. 

(->i ([lst list?])
       ([#:foo (lst) (….etc)))
      (result list?))

doesn’t work for me, neither does sticking an id before or after … (lat) … 

Does anyone have an example of an optional keyword ->i contract? This would 
seem to be an extremely useful form, but the examples in the documentation do 
not appear to cover it. They do cover the ->* form, but not the ->i for that 
combination.

Thanks!

-Kevin
____________________
  Racket Users list:
  http://lists.racket-lang.org/users

Reply via email to