diff options
author | Araq <rumpf_a@web.de> | 2014-09-11 00:34:59 +0200 |
---|---|---|
committer | Araq <rumpf_a@web.de> | 2014-09-11 00:34:59 +0200 |
commit | 2c99991d169d66d5fd2334cfc783761d1ffe25bc (patch) | |
tree | 1532d954d0ad9fc2aee117692a59459892ebbe91 /lib/pure | |
parent | dcc00b3960d67ec03414d02a8958335caaa5f22b (diff) | |
download | Nim-2c99991d169d66d5fd2334cfc783761d1ffe25bc.tar.gz |
fixes #1444
Diffstat (limited to 'lib/pure')
-rw-r--r-- | lib/pure/collections/sets.nim | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/pure/collections/sets.nim b/lib/pure/collections/sets.nim index 22eff9c55..ce901963e 100644 --- a/lib/pure/collections/sets.nim +++ b/lib/pure/collections/sets.nim @@ -128,7 +128,7 @@ proc mget*[A](s: var TSet[A], key: A): var A = ## for sharing. assert s.isValid, "The set needs to be initialized." var index = rawGet(s, key) - if index >= 0: result = t.data[index].key + if index >= 0: result = s.data[index].key else: raise newException(EInvalidKey, "key not found: " & $key) proc contains*[A](s: TSet[A], key: A): bool = |