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

add lens-if, lens-cond, and lens-match #148

Merged
merged 3 commits into from
Aug 19, 2015
Merged

Conversation

AlexKnauth
Copy link
Collaborator

> (define if-lens (lens-if list? first-lens (vector-ref-lens 0)))
> (lens-view if-lens '(1 2 3))
1
> (lens-view if-lens '#(1 2 3))
1
> (lens-set if-lens '(1 2 3) 'a)
'(a 2 3)
> (lens-set if-lens '#(1 2 3) 'a)
'#(a 2 3)

@jackfirth
Copy link
Owner

Very cool

jackfirth added a commit that referenced this pull request Aug 19, 2015
add lens-if, lens-cond, and lens-match
@jackfirth jackfirth merged commit 156dd62 into jackfirth:master Aug 19, 2015
@AlexKnauth AlexKnauth deleted the if branch August 19, 2015 22:47
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

Successfully merging this pull request may close these issues.

None yet

2 participants