Skip to content

Commit

Permalink
Subtract spelling error closes #5
Browse files Browse the repository at this point in the history
  • Loading branch information
zoli committed Jul 24, 2016
1 parent 2e6d421 commit 3749fa7
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions regionset.go
Original file line number Diff line number Diff line change
Expand Up @@ -75,8 +75,8 @@ func (r *RegionSet) flush() {
}
}

// Substract (sic #5) removes the given region from the set
func (r *RegionSet) Substract(r2 Region) {
// Subtract removes the given region from the set
func (r *RegionSet) Subtract(r2 Region) {
r3 := r.Cut(r2)
r.lock.Lock()
defer r.lock.Unlock()
Expand Down
2 changes: 1 addition & 1 deletion regionset_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ func TestRegionSubtract(t *testing.T) {
for i, test := range tests {
var v RegionSet
v.AddAll(test.A)
v.Substract(test.B)
v.Subtract(test.B)
if !reflect.DeepEqual(v.Regions(), test.expect) {
t.Errorf("Test %d; Expected %v, got: %v", i, test.expect, v.Regions())
}
Expand Down

0 comments on commit 3749fa7

Please sign in to comment.