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

Unified Diff: mojo/public/tools/bindings/generators/mojom_cpp_generator.py

Issue 615063003: Mojo cpp bindings: support Clone() for structs and arrays which don't contain handles. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 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: mojo/public/tools/bindings/generators/mojom_cpp_generator.py
diff --git a/mojo/public/tools/bindings/generators/mojom_cpp_generator.py b/mojo/public/tools/bindings/generators/mojom_cpp_generator.py
index e5f5e9de9dff0059181dedfbf5699552aa2461e0..68e0379487693e91f3c2d3aa68914081915db732 100644
--- a/mojo/public/tools/bindings/generators/mojom_cpp_generator.py
+++ b/mojo/public/tools/bindings/generators/mojom_cpp_generator.py
@@ -289,6 +289,7 @@ class Generator(generator.Generator):
"has_callbacks": mojom.HasCallbacks,
"should_inline": ShouldInlineStruct,
"is_any_array_kind": mojom.IsAnyArrayKind,
+ "is_cloneable_kind": mojom.IsCloneableKind,
"is_enum_kind": mojom.IsEnumKind,
"is_move_only_kind": mojom.IsMoveOnlyKind,
"is_any_handle_kind": mojom.IsAnyHandleKind,
@@ -297,6 +298,7 @@ class Generator(generator.Generator):
"is_nullable_kind": mojom.IsNullableKind,
"is_object_kind": mojom.IsObjectKind,
"is_string_kind": mojom.IsStringKind,
+ "is_struct_kind": mojom.IsStructKind,
"is_struct_with_handles": IsStructWithHandles,
"struct_size": lambda ps: ps.GetTotalSize() + _HEADER_SIZE,
"struct_from_method": generator.GetStructFromMethod,

Powered by Google App Engine
This is Rietveld 408576698