Skip to content

Commit

Permalink
Slight documentation changes
Browse files Browse the repository at this point in the history
  • Loading branch information
willf committed May 15, 2011
1 parent c39dd76 commit 481798e
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 9 deletions.
21 changes: 14 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,22 @@ Package bitset implements bitsets.

It provides methods for making a BitSet of an arbitrary
upper limit, setting and testing bit locations, and clearing
bit locations as well as the entire set.
bit locations as well as the entire set, counting the number
of bits.

It also supports set intersection, union, difference and
symmetric difference, cloning, equality testing, and subsetting.

Example use:

b := bitset.New(64000)
b.SetBit(1000)
if b.Bit(1000) {
b.ClearBit(1000)
}

import "bitset"
b := bitset.New(64000)
b.SetBit(1000)
b.SetBit(999)
if b.Bit(1000) {
b.ClearBit(1000)
}
b.Clear()

Discussion at: [golang-nuts Google Group](https://groups.google.com/d/topic/golang-nuts/7n1VkRTlBf4/discussion)

9 changes: 7 additions & 2 deletions bitset.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,15 @@
It provides methods for making a BitSet of an arbitrary
upper limit, setting and testing bit locations, and clearing
bit locations as well as the entire set.
bit locations as well as the entire set, counting the number
of bits.
It also supports set intersection, union, difference and
symmetric difference, cloning, equality testing, and subsetting.
Example use:
import "bitset"
b := bitset.New(64000)
b.SetBit(1000)
b.SetBit(999)
Expand Down

0 comments on commit 481798e

Please sign in to comment.