Index: third_party/protobuf/src/google/protobuf/unittest_mset.proto |
diff --git a/third_party/protobuf/src/google/protobuf/unittest_mset.proto b/third_party/protobuf/src/google/protobuf/unittest_mset.proto |
index 3497f09fa6d41b7b38357e7f2610dfb5c087d3e4..49d9adad0b699f7fe67c64f997b2761e8a73f8d1 100644 |
--- a/third_party/protobuf/src/google/protobuf/unittest_mset.proto |
+++ b/third_party/protobuf/src/google/protobuf/unittest_mset.proto |
@@ -1,6 +1,6 @@ |
// Protocol Buffers - Google's data interchange format |
// Copyright 2008 Google Inc. All rights reserved. |
-// http://code.google.com/p/protobuf/ |
+// https://developers.google.com/protocol-buffers/ |
// |
// Redistribution and use in source and binary forms, with or without |
// modification, are permitted provided that the following conditions are |
@@ -32,36 +32,47 @@ |
// Based on original Protocol Buffers design by |
// Sanjay Ghemawat, Jeff Dean, and others. |
// |
-// This file contains messages for testing message_set_wire_format. |
+// This file is similar to unittest_mset_wire_format.proto, but does not |
+// have a TestMessageSet, so it can be downgraded to proto1. |
+ |
+syntax = "proto2"; |
+ |
+import "google/protobuf/unittest_mset_wire_format.proto"; |
package protobuf_unittest; |
+option cc_enable_arenas = true; |
option optimize_for = SPEED; |
-// A message with message_set_wire_format. |
-message TestMessageSet { |
- option message_set_wire_format = true; |
- extensions 4 to max; |
-} |
- |
message TestMessageSetContainer { |
- optional TestMessageSet message_set = 1; |
+ optional proto2_wireformat_unittest.TestMessageSet message_set = 1; |
} |
message TestMessageSetExtension1 { |
- extend TestMessageSet { |
+ extend proto2_wireformat_unittest.TestMessageSet { |
optional TestMessageSetExtension1 message_set_extension = 1545008; |
} |
optional int32 i = 15; |
} |
message TestMessageSetExtension2 { |
- extend TestMessageSet { |
+ extend proto2_wireformat_unittest.TestMessageSet { |
optional TestMessageSetExtension2 message_set_extension = 1547769; |
} |
optional string str = 25; |
} |
+// This message was used to generate |
+// //net/proto2/python/internal/testdata/message_set_message, but is commented |
+// out since it must not actually exist in code, to simulate an "unknown" |
+// extension. |
+// message TestMessageSetUnknownExtension { |
+// extend TestMessageSet { |
+// optional TestMessageSetUnknownExtension message_set_extension = 56141421; |
+// } |
+// optional int64 a = 1; |
+// } |
+ |
// MessageSet wire format is equivalent to this. |
message RawMessageSet { |
repeated group Item = 1 { |
@@ -69,4 +80,3 @@ message RawMessageSet { |
required bytes message = 3; |
} |
} |
- |