Index: third_party/mojo/src/mojo/public/tools/bindings/generators/cpp_templates/wrapper_union_class_declaration.tmpl |
diff --git a/third_party/mojo/src/mojo/public/tools/bindings/generators/cpp_templates/wrapper_union_class_declaration.tmpl b/third_party/mojo/src/mojo/public/tools/bindings/generators/cpp_templates/wrapper_union_class_declaration.tmpl |
index 2f931bf3fd6ae82bf22c52972fef329dead93f59..5e43c433b03da969fab8798b8d6313fe048bf298 100644 |
--- a/third_party/mojo/src/mojo/public/tools/bindings/generators/cpp_templates/wrapper_union_class_declaration.tmpl |
+++ b/third_party/mojo/src/mojo/public/tools/bindings/generators/cpp_templates/wrapper_union_class_declaration.tmpl |
@@ -39,7 +39,8 @@ class {{union.name}} { |
Union_() {} |
~Union_() {} |
{% for field in union.fields %} |
-{% if field.kind|is_object_kind or field.kind|is_any_handle_kind -%} |
+{% if field.kind|is_object_kind or field.kind|is_any_handle_kind |
+ or field.kind|is_interface_kind -%} |
{{field.kind|cpp_wrapper_type}}* {{field.name}}; |
{% else -%} |
{{field.kind|cpp_wrapper_type}} {{field.name}}; |