Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Contract documentation improvement: anonymous contracts #4

Open
goodmike opened this issue Jul 2, 2010 · 1 comment
Open

Contract documentation improvement: anonymous contracts #4

goodmike opened this issue Jul 2, 2010 · 1 comment

Comments

@goodmike
Copy link
Contributor

goodmike commented Jul 2, 2010

I think it's worth demonstrating that 'with-constraints' can take an anonymous contract instead of a named contract:

(def sqr-8bit
  (with-constraints
  constrained-sqr
  (contract 
    [n]
    :requires
    (< n 16)
    integer?
    pos?)))
@fogus
Copy link
Owner

fogus commented Jul 2, 2010

Agreed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants