Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(105)

Unified Diff: third_party/WebKit/Source/bindings/templates/attributes.cpp.tmpl

Issue 2785943002: [Bindings] Simplify V8PrivateProperty::Symbol methods (Closed)
Patch Set: work for comments Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/bindings/templates/attributes.cpp.tmpl
diff --git a/third_party/WebKit/Source/bindings/templates/attributes.cpp.tmpl b/third_party/WebKit/Source/bindings/templates/attributes.cpp.tmpl
index 7f7dc8cd932553b87f4c7c8729a6856cd4984ccc..d14ade75d64b87d4606eafce8d11c7e56e68bbcf 100644
--- a/third_party/WebKit/Source/bindings/templates/attributes.cpp.tmpl
+++ b/third_party/WebKit/Source/bindings/templates/attributes.cpp.tmpl
@@ -34,7 +34,7 @@ const v8::FunctionCallbackInfo<v8::Value>& info
// X(SameObject, {{same_object_private_key}})
auto privateSameObject = V8PrivateProperty::getSameObject{{same_object_private_key}}(info.GetIsolate());
{
- v8::Local<v8::Value> v8Value = privateSameObject.get(info.GetIsolate()->GetCurrentContext(), holder);
+ v8::Local<v8::Value> v8Value = privateSameObject.getOrEmpty(holder);
if (!v8Value.IsEmpty()) {
v8SetReturnValue(info, v8Value);
return;
@@ -163,7 +163,7 @@ const v8::FunctionCallbackInfo<v8::Value>& info
{% if attribute.is_save_same_object %}
// [SaveSameObject]
- privateSameObject.set(info.GetIsolate()->GetCurrentContext(), holder, info.GetReturnValue().Get());
+ privateSameObject.set(holder, info.GetReturnValue().Get());
{% endif %}
{% endfilter %}{# format_remove_duplicates #}
}

Powered by Google App Engine
This is Rietveld 408576698