(flat-contract-with-explanation get-explanation [#:name name]) →
get-explanation : (-> any/c (or/c boolean? (-> blame? any)))
name : any/c = (object-name get-explanation)
When I try to create a contract that means "a list of length >= 2", I
get the following:
(cond [(and (list? l) (>= (length l) 2))]
(raise-blame-error blame l '(expected: "list with length >=
2"\ngiven: "~e" )))]))
; application: procedure does not accept keyword arguments
; procedure: flat-contract-with-explanation
What am I not understanding?
PS: I know I could do (-> (and/c list? (lambda (l) (>= (length l)
2)))) any) but I wanted to get something that wouldn't return ??? in
the error message
You received this message because you are subscribed to the Google Groups
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
For more options, visit https://groups.google.com/d/optout.