diff options
author | Andreas Rumpf <rumpf_a@web.de> | 2014-06-12 16:39:20 +0200 |
---|---|---|
committer | Andreas Rumpf <rumpf_a@web.de> | 2014-06-12 16:39:20 +0200 |
commit | d927eb5854e9c6c005344bc81d4632ffc8f5d975 (patch) | |
tree | 145a26a74dd4b93f67f5a1ae70602133df12960d /lib/pure/collections/tables.nim | |
parent | d3c8f1ab25a810516baccc2b1bff761dbbc2d011 (diff) | |
parent | af6abac4911be18bd92a9190ccbe39aa72ab1a79 (diff) | |
download | Nim-d927eb5854e9c6c005344bc81d4632ffc8f5d975.tar.gz |
Merge pull request #1251 from gradha/pr_misc_docs
Misc docs suggestions
Diffstat (limited to 'lib/pure/collections/tables.nim')
-rw-r--r-- | lib/pure/collections/tables.nim | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/pure/collections/tables.nim b/lib/pure/collections/tables.nim index 091bf8590..ce9df09e1 100644 --- a/lib/pure/collections/tables.nim +++ b/lib/pure/collections/tables.nim @@ -37,7 +37,8 @@ ## ## Piggyback on the already available string hash proc. ## ## ## ## Without this proc nothing works! -## result = hash(x.firstName & x.lastName) +## result = x.firstName.hash !& x.lastName.hash +## result = !$result ## ## var ## salaries = initTable[Person, int]() @@ -848,7 +849,8 @@ when isMainModule: ## Piggyback on the already available string hash proc. ## ## Without this proc nothing works! - result = hash(x.firstName & x.lastName) + result = x.firstName.hash !& x.lastName.hash + result = !$result var salaries = initTable[Person, int]() |