Protocol Buffers - Google's data interchange format (grpc依赖)
https://developers.google.com/protocol-buffers/
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
36 lines
847 B
36 lines
847 B
// Protocol Buffers - Google's data interchange format |
|
// Copyright 2023 Google LLC. All rights reserved. |
|
// |
|
// Use of this source code is governed by a BSD-style |
|
// license that can be found in the LICENSE file or at |
|
// https://developers.google.com/open-source/licenses/bsd |
|
|
|
// LINT: LEGACY_NAMES |
|
// The purpose of this file is to be as hostile as possible to reserved words |
|
// to the Rust language and ensure it still works. |
|
|
|
syntax = "proto2"; |
|
|
|
// Note: Ideally this test could be 'package type.if.else.true.false' |
|
// which would work in Rust but would break the C++ codegen. |
|
|
|
package type.type; |
|
|
|
message Self { |
|
optional int32 for = 1; |
|
optional Self self = 2; |
|
optional bool true = 3; |
|
optional string false = 4; |
|
} |
|
|
|
message pub { |
|
enum Self { |
|
enum = 0; |
|
} |
|
} |
|
|
|
message enum { |
|
oneof self { |
|
.type.type.pub.Self const = 3; |
|
} |
|
}
|
|
|