Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ruanhaishen
redis
Commits
7bd45659
Commit
7bd45659
authored
Oct 25, 2013
by
antirez
Browse files
Fixed typos in dictScan() comment.
parent
34c20722
Changes
1
Show whitespace changes
Inline
Side-by-side
src/dict.c
View file @
7bd45659
...
...
@@ -698,7 +698,7 @@ static unsigned long rev(unsigned long v) {
* (in binary) 1111. The position of a key in the hash table will be always
* the last four bits of the hash output, and so forth.
*
* WHAT HAPPENS
DURING REHASHING, WHEN YOU HAVE TWO TABLES
?
* WHAT HAPPENS
IF THE TABLE CHANGES IN SIZE
?
*
* If the hash table grows, elements can go anyway in one multiple of
* the old bucket: for example let's say that we already iterated with
...
...
@@ -720,7 +720,7 @@ static unsigned long rev(unsigned long v) {
* as we are sure that, we tried for example, both 0111 and 1111 (all the
* variations of the higher bit) so we don't need to test it again.
*
*
But wait... You have *two* tables in a given moment during rehashing
!
*
WAIT... YOU HAVE *TWO* TABLES DURING REHASHING
!
*
* Yes, this is true, but we always iterate the smaller one of the tables,
* testing also all the expansions of the current cursor into the larger
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment