Skip to content

Commit

Permalink
Fixed __and__ for set.coffee to do inplace or on the intersect set, a…
Browse files Browse the repository at this point in the history
…nd to look at the objects(not hashes) returned from the underlying dictionary's keys()
  • Loading branch information
Onur Karaman committed Mar 22, 2012
1 parent edae80a commit 6af9ea5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/builtin/set.coffee
Expand Up @@ -8,7 +8,7 @@ class Set extends Iterable

__and__: (otherSet) ->
intersect = new Set()
intersect.__or__(item) for item of @value.value when otherSet.__contains__(item).value
intersect.__ior__(item) for item of @value.keys().value when otherSet.__contains__(item).value
return intersect

__cmp__: (otherSet) ->
Expand Down

0 comments on commit 6af9ea5

Please sign in to comment.