[Webkit-unassigned] [Bug 43276] Implements IDBKeyPath extractor.

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Aug 2 03:04:38 PDT 2010


https://bugs.webkit.org/show_bug.cgi?id=43276





--- Comment #5 from Andrei Popescu <andreip at google.com>  2010-08-02 03:04:38 PST ---
> WebCore/bindings/v8/SerializedScriptValue.cpp
> String keyPathExtractor(const String& wireData, const String& keyPathString)

Does the above IDB-specific method belong to the SerializedScriptValue file? I think Jeremy added a IDBBindingsUtils class that seems more fit for your purpose.

Also, is this method used just for testing? Otherwise, I am a bit confused about why it always returns a string. 

And one last thing: is the current name the best choice? You're not extracting a key path. You're extracting a value from the serialized object at the given key path.

> void IDBKeyPath::parse()
> (...)
>  case Array : {
> (...)
> m_lexer.next();
 > token = m_lexer.currentToken();

You are only checking for dot or left bracket. But what if tokEnd follows? Seems like you're returning ParserErrorAfterArray in that case? Although looking at the unit tests, it seems you have cases for key paths that end indexing into an array.

> class LocalContext {

Umm, do you need this? Isn't this the same as v8::Context::Scope?

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list