Fix probing in JSON.parse.
R=verwaest@chromium.org BUG= Review URL: https://chromiumcodereview.appspot.com/10989032 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@12622 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
This commit is contained in:
parent
944f933332
commit
29b6518874
@ -590,10 +590,10 @@ Handle<String> JsonParser<seq_ascii>::ScanJsonString() {
|
||||
seq_source_->GetChars() + position_, length);
|
||||
SymbolTable* symbol_table = isolate()->heap()->symbol_table();
|
||||
uint32_t capacity = symbol_table->Capacity();
|
||||
uint32_t index = SymbolTable::FirstProbe(hash, capacity);
|
||||
uint32_t entry = SymbolTable::FirstProbe(hash, capacity);
|
||||
uint32_t count = 1;
|
||||
while (true) {
|
||||
Object* element = symbol_table->KeyAt(index);
|
||||
Object* element = symbol_table->KeyAt(entry);
|
||||
if (element == isolate()->heap()->raw_unchecked_undefined_value()) {
|
||||
// Lookup failure.
|
||||
break;
|
||||
@ -606,7 +606,7 @@ Handle<String> JsonParser<seq_ascii>::ScanJsonString() {
|
||||
AdvanceSkipWhitespace();
|
||||
return Handle<String>(String::cast(element));
|
||||
}
|
||||
index = SymbolTable::NextProbe(hash, count++, capacity);
|
||||
entry = SymbolTable::NextProbe(entry, count++, capacity);
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user