home
/
code
/
hope.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Update line breaks to a more consistent style.
[hope.git]
/
src
/
hope_option.erl
diff --git
a/src/hope_option.erl
b/src/hope_option.erl
index
ad0adac
..
622c06d
100644
(file)
--- a/
src/hope_option.erl
+++ b/
src/hope_option.erl
@@
-1,15
+1,21
@@
-module(hope_option).
-module(hope_option).
--export_type([ t/1
- ]).
--export([ put/2
- , get/2
- , map/2
- ]).
+-export_type(
+ [ t/1
+ ]).
+-export(
+ [ put/2
+ , get/2
+ , map/2
+ ]).
--type t(A) :: none | {some, A}.
+
+-type t(A) ::
+ none
+ | {some, A}
+ .
put(X, F) ->
put(X, F) ->
@@
-18,10
+24,8
@@
put(X, F) ->
; false -> none
end.
; false -> none
end.
-
get({some, X}, _) -> X;
get(none , Y) -> Y.
get({some, X}, _) -> X;
get(none , Y) -> Y.
-
map({some, X}, F) -> {some, F(X)};
map(none , _) -> none.
map({some, X}, F) -> {some, F(X)};
map(none , _) -> none.
This page took
0.025605 seconds
and
4
git commands to generate.