Skip to content

Commit b26304f

Browse files
author
José Valim
committed
Improve docs
1 parent 1c834e8 commit b26304f

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

lib/elixir/lib/enum.ex

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -85,10 +85,10 @@ defprotocol Enumerable do
8585
@type continuation :: (acc -> result)
8686

8787
@doc """
88-
The reduce function.
88+
Reduces the collection into a value.
8989
9090
Most of the operations in `Enum` are implemented in terms of reduce.
91-
This function shuold simply apply the given `reducer` function to each
91+
This function should simply apply the given `reducer` function to each
9292
item in the collection and proceed as expected by the returned accumulator.
9393
9494
As an example, here is the implementation of `reduce` for lists:
@@ -103,15 +103,15 @@ defprotocol Enumerable do
103103
def reduce(collection, acc, fun)
104104

105105
@doc """
106-
Check if a value exists within the collection.
106+
Checks if a value exists within the collection.
107107
108108
Membership should be tested with the match (`===`) operator.
109109
"""
110110
@spec member?(t, term) :: boolean
111111
def member?(collection, value)
112112

113113
@doc """
114-
Retrieve the collection' size.
114+
Retrieves the collection's size.
115115
"""
116116
@spec count(t) :: non_neg_integer
117117
def count(collection)

0 commit comments

Comments
 (0)