Merge pull request #244 from jackfirth/237-lens-join-hash-examples
Use clearer example for lens-join/hash
This commit is contained in:
commit
43884cb0c4
|
@ -10,8 +10,9 @@
|
||||||
if lenses share views later lenses take precedence when
|
if lenses share views later lenses take precedence when
|
||||||
setting.
|
setting.
|
||||||
@lens-examples[
|
@lens-examples[
|
||||||
(define a-b-lens (lens-join/hash 'a first-lens
|
(define first-third-hash-lens
|
||||||
'b third-lens))
|
(lens-join/hash 'first first-lens
|
||||||
(lens-view a-b-lens '(1 2 3))
|
'third third-lens))
|
||||||
(lens-set a-b-lens '(1 2 3) (hash 'a 100 'b 200))
|
(lens-view first-third-hash-lens '(1 2 3))
|
||||||
|
(lens-set first-third-hash-lens '(1 2 3) (hash 'first 100 'third 200))
|
||||||
]}
|
]}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user