Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Add some more infix-style demos
  • Loading branch information
NicolasT committed May 16, 2010
1 parent d585482 commit 22feeca
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions demo/functor.py
Expand Up @@ -73,6 +73,8 @@
# Using infix-style operators
assert (lambda i: i * 2) <<fmap>> (lambda i: i + 1) <<fmap>> demo_list == \
[2, 4, 6, 8]
assert f <<fmap>> Just(1) <<eq>> Just(2)
assert f <<fmap>> f <<fmap>> Nothing <<eq>> Nothing


# Functor laws
Expand Down

0 comments on commit 22feeca

Please sign in to comment.