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

Unified Diff: third_party/WebKit/Source/bindings/templates/union_container.h.tmpl

Issue 2709983004: WIP bindings: Add support for the record<K,V> WebIDL type. (Closed)
Patch Set: Rebased patch using NativeValueTraits for IDL types Created 3 years, 10 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/union_container.h.tmpl
diff --git a/third_party/WebKit/Source/bindings/templates/union_container.h.tmpl b/third_party/WebKit/Source/bindings/templates/union_container.h.tmpl
index fd29d46cc6c32b1f25784fafab5da84d7a94faac..39ad7e0d94a51044639a6750df36eeda0658dc1d 100644
--- a/third_party/WebKit/Source/bindings/templates/union_container.h.tmpl
+++ b/third_party/WebKit/Source/bindings/templates/union_container.h.tmpl
@@ -67,9 +67,15 @@ inline void v8SetReturnValue(const CallbackInfo& callbackInfo, {{cpp_class}}& im
template <>
struct NativeValueTraits<{{cpp_class}}> {
+ using ImplType = {{cpp_class}};
{{exported}}static {{cpp_class}} nativeValue(v8::Isolate*, v8::Local<v8::Value>, ExceptionState&);
};
+template <>
+struct V8TypeOf<{{cpp_class}}> {
+ typedef {{v8_class}} Type;
+};
+
} // namespace blink
// We need to set canInitializeWithMemset=true because HeapVector supports

Powered by Google App Engine
This is Rietveld 408576698