Skip to content

Commit

Permalink
Add brief documentation for IntSet
Browse files Browse the repository at this point in the history
  • Loading branch information
mbauman committed Aug 9, 2015
1 parent 8a12923 commit 7e2112d
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ This package implements a variety of data structures, including
* Trie
* Linked List
* Sorted Dict, Sorted Multi-Dict and Sorted Set
* DataStructures.IntSet

------
Deque
Expand Down Expand Up @@ -363,6 +364,21 @@ A list of sequentially linked nodes. This allows efficient insertion of nodes to
julia> for i in l5; print(i); end
246

---------------------
DataStructures.IntSet
---------------------

`DataStructures.IntSet` is a drop-in replacement for the Base `IntSet` type. It
efficiently stores dense collections of small non-negative `Int`s as a sorted
set. The constructor `IntSet([itr])` constructs a sorted set of the integers
generated by the given iterable object, or an empty set if no argument is
given. If the set will be sparse (for example holding a few very large
integers), use `Set` or `SortedSet` instead.

A complement IntSet may be constructed with `complement` or `complement!`. The
complement of an empty `IntSet` contains `typemax(Int)` elements from 0 to
`typemax(Int)-1`.

----------------------------------------
Overview of Sorted Containers
----------------------------------------
Expand Down

0 comments on commit 7e2112d

Please sign in to comment.