on master help sign in
get rid of documentation for functions that are not exported
commit44057afdb031449e5a665eab0fb854e4b3d9b5ff authorEvan Czaplicki <info@elm-lang.org> dateFri 18 Oct 2013, 01:11 (13 years ago) parente0b0cc0
2 files changed−17
libraries/Either.elm−12 libraries/Maybe.elm−5
libraries/Either.elm−12
@@ -52,28 +52,16 @@ have the equivalence: `(partition es == (lefts es, rights es))`
5252partition : [Either a b] -> ([a],[b])
5353partition es = List.foldr consEither ([],[]) es
5454
55−{-| If `Left`, add the value to the front of the list.
56−If `Right`, return the list unchanged
57−-}
58−consLeft : Either a b -> [a] -> [a]
5955consLeft e vs =
6056 case e of
6157 Left v -> v::vs
6258 Right _ -> vs
6359
64−{-| If `Right`, add the value to the front of the list.
65−If `Left`, return the list unchanged.
66−-}
67−consRight : Either a b -> [b] -> [b]
6860consRight e vs =
6961 case e of
7062 Left _ -> vs
7163 Right v -> v::vs
7264
73−{-| If `Left`, add the value to the left list.
74−If `Right`, add the value to the right list.
75−-}
76−consEither : Either a b -> ([a], [b]) -> ([a], [b])
7765consEither e (ls,rs) =
7866 case e of
7967 Left l -> (l::ls,rs)
libraries/Maybe.elm−5
@@ -39,11 +39,6 @@ isJust = maybe False (\_ -> True)
3939isNothing : Maybe a -> Bool
4040isNothing = not . isJust
4141
42−
43−{-| If `Just`, adds the value to the front of the list.
44−If `Nothing`, list is unchanged.
45−-}
46−cons : Maybe a -> [a] -> [a]
4742cons mx xs = maybe xs (\x -> x :: xs) mx
4843
4944{-| Filters out Nothings and extracts the remaining values.