Index: mojo/public/interfaces/bindings/tests/test_structs.mojom |
diff --git a/mojo/public/interfaces/bindings/tests/test_structs.mojom b/mojo/public/interfaces/bindings/tests/test_structs.mojom |
index 6af00866fec053dbc001cc1572a839ca01d6e611..7674611778b738a67a81588d2cf3f26b57b0afd0 100644 |
--- a/mojo/public/interfaces/bindings/tests/test_structs.mojom |
+++ b/mojo/public/interfaces/bindings/tests/test_structs.mojom |
@@ -108,4 +108,31 @@ struct ScopedConstants { |
int32 f6 = ALSO_TEN; |
}; |
-} |
+// Used to verify that all possible Map key field types can be encoded and |
+// decoded successfully. |
+ |
+struct MapKeyTypes { |
+ map<bool, bool> f0; |
+ map<int8, int8> f1; |
+ map<uint8, uint8> f2; |
+ map<int16, int16> f3; |
+ map<uint16, uint16> f4; |
+ map<int32, int32> f5; |
+ map<uint32, uint32> f6; |
+ map<int64, int64> f7; |
+ map<uint64, uint64> f8; |
+ map<float, float> f9; |
+ map<double, double> f10; |
+ map<string, string> f11; |
+}; |
+ |
+// Used to verify that some common value types can be encoded and decoded |
+// successfully. |
+ |
+struct MapValueTypes { |
+ map<string, array<string>> f0; |
+ map<string, array<string>?> f1; |
+ map<string, array<string?>> f2; |
+}; |
+ |
+} |