Skip to content

Commit f5240c3

Browse files
authored
Clarify Set's enumeration order (#16274)
1 parent 3063436 commit f5240c3

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/set.cr

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
1-
# `Set` implements a collection of unordered values with no duplicates.
1+
# `Set` implements a collection of values with no duplicates.
22
#
33
# An `Enumerable` object can be converted to `Set` using the `#to_set` method.
44
#
55
# `Set` uses `Hash` as storage, so you must note the following points:
66
#
77
# * Equality of elements is determined according to `Object#==` and `Object#hash`.
8+
# * Enumeration follows the order that the elements were inserted.
89
# * `Set` assumes that the identity of each element does not change while it is stored. Modifying an element of a set will render the set to an unreliable state.
910
#
1011
# ### Example

0 commit comments

Comments
 (0)