mirror of
https://gitlab.com/pulsechaincom/prysm-pulse.git
synced 2024-12-27 21:57:16 +00:00
49a0d3caf0
* Fix a few deps to work with go.mod, check in generated files * Update Gossipsub to 1.1 (#5998) * update libs * add new validators * add new deps * new set of deps * tls * further fix gossip update * get everything to build * clean up * gaz * fix build * fix all tests * add deps to images * imports Co-authored-by: rauljordan <raul@prysmaticlabs.com> * Beacon chain builds with go build * fix bazel * fix dep * lint * Add github action for testing go * on PR for any branch * fix libp2p test failure * Fix TestProcessBlock_PassesProcessingConditions by updating the proposer index in test * Revert "Fix TestProcessBlock_PassesProcessingConditions by updating the proposer index in test" This reverts commit 43676894ab01f03fe90a9b8ee3ecfbc2ec1ec4e4. * Compute and set proposer index instead of hard code * Add back go mod/sum, fix deps * go build ./... * Temporarily skip two tests * Fix kafka confluent patch * Fix kafka confluent patch * fix kafka build * fix kafka * Add info in DEPENDENCIES. Added a stub link for Why Bazel? until https://github.com/prysmaticlabs/documentation/issues/138 * Update fuzz ssz files as well * Update fuzz ssz files as well * getting closer * rollback rules_go and gazelle * fix gogo protobuf * install librdkafka-dev as part of github actions * Update kafka to a recent version where librkafkfa is not required for go modules * clarify comment * fix kafka build * disable go tests * comment * Fix geth dependencies for end to end * rename word * lint * fix docker Co-authored-by: Nishant Das <nishdas93@gmail.com> Co-authored-by: rauljordan <raul@prysmaticlabs.com> Co-authored-by: terence tsao <terence@prysmaticlabs.com>
1940 lines
45 KiB
Go
Executable File
Generated
1940 lines
45 KiB
Go
Executable File
Generated
// Code generated by protoc-gen-gogo. DO NOT EDIT.
|
|
// source: proto/testing/test.proto
|
|
|
|
package testing
|
|
|
|
import (
|
|
fmt "fmt"
|
|
io "io"
|
|
math "math"
|
|
math_bits "math/bits"
|
|
|
|
_ "github.com/gogo/protobuf/gogoproto"
|
|
proto "github.com/gogo/protobuf/proto"
|
|
types "github.com/gogo/protobuf/types"
|
|
)
|
|
|
|
// Reference imports to suppress errors if they are not otherwise used.
|
|
var _ = proto.Marshal
|
|
var _ = fmt.Errorf
|
|
var _ = math.Inf
|
|
|
|
// This is a compile-time assertion to ensure that this generated file
|
|
// is compatible with the proto package it is being compiled against.
|
|
// A compilation error at this line likely means your copy of the
|
|
// proto package needs to be updated.
|
|
const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package
|
|
|
|
type Person_PhoneType int32
|
|
|
|
const (
|
|
Person_MOBILE Person_PhoneType = 0
|
|
Person_HOME Person_PhoneType = 1
|
|
Person_WORK Person_PhoneType = 2
|
|
)
|
|
|
|
var Person_PhoneType_name = map[int32]string{
|
|
0: "MOBILE",
|
|
1: "HOME",
|
|
2: "WORK",
|
|
}
|
|
|
|
var Person_PhoneType_value = map[string]int32{
|
|
"MOBILE": 0,
|
|
"HOME": 1,
|
|
"WORK": 2,
|
|
}
|
|
|
|
func (x Person_PhoneType) String() string {
|
|
return proto.EnumName(Person_PhoneType_name, int32(x))
|
|
}
|
|
|
|
func (Person_PhoneType) EnumDescriptor() ([]byte, []int) {
|
|
return fileDescriptor_1f902154cb7707ef, []int{3, 0}
|
|
}
|
|
|
|
type TestMessage struct {
|
|
Foo string `protobuf:"bytes,1,opt,name=foo,proto3" json:"foo,omitempty"`
|
|
Bar string `protobuf:"bytes,2,opt,name=bar,proto3" json:"bar,omitempty" fizz:"buzz" spec-name:"baz"`
|
|
XXX_NoUnkeyedLiteral struct{} `json:"-"`
|
|
XXX_unrecognized []byte `json:"-"`
|
|
XXX_sizecache int32 `json:"-"`
|
|
}
|
|
|
|
func (m *TestMessage) Reset() { *m = TestMessage{} }
|
|
func (m *TestMessage) String() string { return proto.CompactTextString(m) }
|
|
func (*TestMessage) ProtoMessage() {}
|
|
func (*TestMessage) Descriptor() ([]byte, []int) {
|
|
return fileDescriptor_1f902154cb7707ef, []int{0}
|
|
}
|
|
func (m *TestMessage) XXX_Unmarshal(b []byte) error {
|
|
return m.Unmarshal(b)
|
|
}
|
|
func (m *TestMessage) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
|
|
if deterministic {
|
|
return xxx_messageInfo_TestMessage.Marshal(b, m, deterministic)
|
|
} else {
|
|
b = b[:cap(b)]
|
|
n, err := m.MarshalToSizedBuffer(b)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return b[:n], nil
|
|
}
|
|
}
|
|
func (m *TestMessage) XXX_Merge(src proto.Message) {
|
|
xxx_messageInfo_TestMessage.Merge(m, src)
|
|
}
|
|
func (m *TestMessage) XXX_Size() int {
|
|
return m.Size()
|
|
}
|
|
func (m *TestMessage) XXX_DiscardUnknown() {
|
|
xxx_messageInfo_TestMessage.DiscardUnknown(m)
|
|
}
|
|
|
|
var xxx_messageInfo_TestMessage proto.InternalMessageInfo
|
|
|
|
func (m *TestMessage) GetFoo() string {
|
|
if m != nil {
|
|
return m.Foo
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (m *TestMessage) GetBar() string {
|
|
if m != nil {
|
|
return m.Bar
|
|
}
|
|
return ""
|
|
}
|
|
|
|
type TestNestedMessage struct {
|
|
Fuzz string `protobuf:"bytes,1,opt,name=fuzz,proto3" json:"fuzz,omitempty"`
|
|
Msg *TestMessage `protobuf:"bytes,2,opt,name=msg,proto3" json:"msg,omitempty"`
|
|
XXX_NoUnkeyedLiteral struct{} `json:"-"`
|
|
XXX_unrecognized []byte `json:"-"`
|
|
XXX_sizecache int32 `json:"-"`
|
|
}
|
|
|
|
func (m *TestNestedMessage) Reset() { *m = TestNestedMessage{} }
|
|
func (m *TestNestedMessage) String() string { return proto.CompactTextString(m) }
|
|
func (*TestNestedMessage) ProtoMessage() {}
|
|
func (*TestNestedMessage) Descriptor() ([]byte, []int) {
|
|
return fileDescriptor_1f902154cb7707ef, []int{1}
|
|
}
|
|
func (m *TestNestedMessage) XXX_Unmarshal(b []byte) error {
|
|
return m.Unmarshal(b)
|
|
}
|
|
func (m *TestNestedMessage) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
|
|
if deterministic {
|
|
return xxx_messageInfo_TestNestedMessage.Marshal(b, m, deterministic)
|
|
} else {
|
|
b = b[:cap(b)]
|
|
n, err := m.MarshalToSizedBuffer(b)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return b[:n], nil
|
|
}
|
|
}
|
|
func (m *TestNestedMessage) XXX_Merge(src proto.Message) {
|
|
xxx_messageInfo_TestNestedMessage.Merge(m, src)
|
|
}
|
|
func (m *TestNestedMessage) XXX_Size() int {
|
|
return m.Size()
|
|
}
|
|
func (m *TestNestedMessage) XXX_DiscardUnknown() {
|
|
xxx_messageInfo_TestNestedMessage.DiscardUnknown(m)
|
|
}
|
|
|
|
var xxx_messageInfo_TestNestedMessage proto.InternalMessageInfo
|
|
|
|
func (m *TestNestedMessage) GetFuzz() string {
|
|
if m != nil {
|
|
return m.Fuzz
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (m *TestNestedMessage) GetMsg() *TestMessage {
|
|
if m != nil {
|
|
return m.Msg
|
|
}
|
|
return nil
|
|
}
|
|
|
|
type Puzzle struct {
|
|
Challenge string `protobuf:"bytes,1,opt,name=challenge,proto3" json:"challenge,omitempty"`
|
|
Answer string `protobuf:"bytes,2,opt,name=answer,proto3" json:"answer,omitempty"`
|
|
XXX_NoUnkeyedLiteral struct{} `json:"-"`
|
|
XXX_unrecognized []byte `json:"-"`
|
|
XXX_sizecache int32 `json:"-"`
|
|
}
|
|
|
|
func (m *Puzzle) Reset() { *m = Puzzle{} }
|
|
func (m *Puzzle) String() string { return proto.CompactTextString(m) }
|
|
func (*Puzzle) ProtoMessage() {}
|
|
func (*Puzzle) Descriptor() ([]byte, []int) {
|
|
return fileDescriptor_1f902154cb7707ef, []int{2}
|
|
}
|
|
func (m *Puzzle) XXX_Unmarshal(b []byte) error {
|
|
return m.Unmarshal(b)
|
|
}
|
|
func (m *Puzzle) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
|
|
if deterministic {
|
|
return xxx_messageInfo_Puzzle.Marshal(b, m, deterministic)
|
|
} else {
|
|
b = b[:cap(b)]
|
|
n, err := m.MarshalToSizedBuffer(b)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return b[:n], nil
|
|
}
|
|
}
|
|
func (m *Puzzle) XXX_Merge(src proto.Message) {
|
|
xxx_messageInfo_Puzzle.Merge(m, src)
|
|
}
|
|
func (m *Puzzle) XXX_Size() int {
|
|
return m.Size()
|
|
}
|
|
func (m *Puzzle) XXX_DiscardUnknown() {
|
|
xxx_messageInfo_Puzzle.DiscardUnknown(m)
|
|
}
|
|
|
|
var xxx_messageInfo_Puzzle proto.InternalMessageInfo
|
|
|
|
func (m *Puzzle) GetChallenge() string {
|
|
if m != nil {
|
|
return m.Challenge
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (m *Puzzle) GetAnswer() string {
|
|
if m != nil {
|
|
return m.Answer
|
|
}
|
|
return ""
|
|
}
|
|
|
|
type Person struct {
|
|
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
|
|
Id int32 `protobuf:"varint,2,opt,name=id,proto3" json:"id,omitempty"`
|
|
Email string `protobuf:"bytes,3,opt,name=email,proto3" json:"email,omitempty"`
|
|
Phones []*Person_PhoneNumber `protobuf:"bytes,4,rep,name=phones,proto3" json:"phones,omitempty"`
|
|
LastUpdated *types.Timestamp `protobuf:"bytes,5,opt,name=last_updated,json=lastUpdated,proto3" json:"last_updated,omitempty"`
|
|
XXX_NoUnkeyedLiteral struct{} `json:"-"`
|
|
XXX_unrecognized []byte `json:"-"`
|
|
XXX_sizecache int32 `json:"-"`
|
|
}
|
|
|
|
func (m *Person) Reset() { *m = Person{} }
|
|
func (m *Person) String() string { return proto.CompactTextString(m) }
|
|
func (*Person) ProtoMessage() {}
|
|
func (*Person) Descriptor() ([]byte, []int) {
|
|
return fileDescriptor_1f902154cb7707ef, []int{3}
|
|
}
|
|
func (m *Person) XXX_Unmarshal(b []byte) error {
|
|
return m.Unmarshal(b)
|
|
}
|
|
func (m *Person) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
|
|
if deterministic {
|
|
return xxx_messageInfo_Person.Marshal(b, m, deterministic)
|
|
} else {
|
|
b = b[:cap(b)]
|
|
n, err := m.MarshalToSizedBuffer(b)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return b[:n], nil
|
|
}
|
|
}
|
|
func (m *Person) XXX_Merge(src proto.Message) {
|
|
xxx_messageInfo_Person.Merge(m, src)
|
|
}
|
|
func (m *Person) XXX_Size() int {
|
|
return m.Size()
|
|
}
|
|
func (m *Person) XXX_DiscardUnknown() {
|
|
xxx_messageInfo_Person.DiscardUnknown(m)
|
|
}
|
|
|
|
var xxx_messageInfo_Person proto.InternalMessageInfo
|
|
|
|
func (m *Person) GetName() string {
|
|
if m != nil {
|
|
return m.Name
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (m *Person) GetId() int32 {
|
|
if m != nil {
|
|
return m.Id
|
|
}
|
|
return 0
|
|
}
|
|
|
|
func (m *Person) GetEmail() string {
|
|
if m != nil {
|
|
return m.Email
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (m *Person) GetPhones() []*Person_PhoneNumber {
|
|
if m != nil {
|
|
return m.Phones
|
|
}
|
|
return nil
|
|
}
|
|
|
|
func (m *Person) GetLastUpdated() *types.Timestamp {
|
|
if m != nil {
|
|
return m.LastUpdated
|
|
}
|
|
return nil
|
|
}
|
|
|
|
type Person_PhoneNumber struct {
|
|
Number string `protobuf:"bytes,1,opt,name=number,proto3" json:"number,omitempty"`
|
|
Type Person_PhoneType `protobuf:"varint,2,opt,name=type,proto3,enum=testing.Person_PhoneType" json:"type,omitempty"`
|
|
XXX_NoUnkeyedLiteral struct{} `json:"-"`
|
|
XXX_unrecognized []byte `json:"-"`
|
|
XXX_sizecache int32 `json:"-"`
|
|
}
|
|
|
|
func (m *Person_PhoneNumber) Reset() { *m = Person_PhoneNumber{} }
|
|
func (m *Person_PhoneNumber) String() string { return proto.CompactTextString(m) }
|
|
func (*Person_PhoneNumber) ProtoMessage() {}
|
|
func (*Person_PhoneNumber) Descriptor() ([]byte, []int) {
|
|
return fileDescriptor_1f902154cb7707ef, []int{3, 0}
|
|
}
|
|
func (m *Person_PhoneNumber) XXX_Unmarshal(b []byte) error {
|
|
return m.Unmarshal(b)
|
|
}
|
|
func (m *Person_PhoneNumber) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
|
|
if deterministic {
|
|
return xxx_messageInfo_Person_PhoneNumber.Marshal(b, m, deterministic)
|
|
} else {
|
|
b = b[:cap(b)]
|
|
n, err := m.MarshalToSizedBuffer(b)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return b[:n], nil
|
|
}
|
|
}
|
|
func (m *Person_PhoneNumber) XXX_Merge(src proto.Message) {
|
|
xxx_messageInfo_Person_PhoneNumber.Merge(m, src)
|
|
}
|
|
func (m *Person_PhoneNumber) XXX_Size() int {
|
|
return m.Size()
|
|
}
|
|
func (m *Person_PhoneNumber) XXX_DiscardUnknown() {
|
|
xxx_messageInfo_Person_PhoneNumber.DiscardUnknown(m)
|
|
}
|
|
|
|
var xxx_messageInfo_Person_PhoneNumber proto.InternalMessageInfo
|
|
|
|
func (m *Person_PhoneNumber) GetNumber() string {
|
|
if m != nil {
|
|
return m.Number
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (m *Person_PhoneNumber) GetType() Person_PhoneType {
|
|
if m != nil {
|
|
return m.Type
|
|
}
|
|
return Person_MOBILE
|
|
}
|
|
|
|
type AddressBook struct {
|
|
People []*Person `protobuf:"bytes,1,rep,name=people,proto3" json:"people,omitempty"`
|
|
XXX_NoUnkeyedLiteral struct{} `json:"-"`
|
|
XXX_unrecognized []byte `json:"-"`
|
|
XXX_sizecache int32 `json:"-"`
|
|
}
|
|
|
|
func (m *AddressBook) Reset() { *m = AddressBook{} }
|
|
func (m *AddressBook) String() string { return proto.CompactTextString(m) }
|
|
func (*AddressBook) ProtoMessage() {}
|
|
func (*AddressBook) Descriptor() ([]byte, []int) {
|
|
return fileDescriptor_1f902154cb7707ef, []int{4}
|
|
}
|
|
func (m *AddressBook) XXX_Unmarshal(b []byte) error {
|
|
return m.Unmarshal(b)
|
|
}
|
|
func (m *AddressBook) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
|
|
if deterministic {
|
|
return xxx_messageInfo_AddressBook.Marshal(b, m, deterministic)
|
|
} else {
|
|
b = b[:cap(b)]
|
|
n, err := m.MarshalToSizedBuffer(b)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return b[:n], nil
|
|
}
|
|
}
|
|
func (m *AddressBook) XXX_Merge(src proto.Message) {
|
|
xxx_messageInfo_AddressBook.Merge(m, src)
|
|
}
|
|
func (m *AddressBook) XXX_Size() int {
|
|
return m.Size()
|
|
}
|
|
func (m *AddressBook) XXX_DiscardUnknown() {
|
|
xxx_messageInfo_AddressBook.DiscardUnknown(m)
|
|
}
|
|
|
|
var xxx_messageInfo_AddressBook proto.InternalMessageInfo
|
|
|
|
func (m *AddressBook) GetPeople() []*Person {
|
|
if m != nil {
|
|
return m.People
|
|
}
|
|
return nil
|
|
}
|
|
|
|
type TestSimpleMessage struct {
|
|
Foo []byte `protobuf:"bytes,1,opt,name=foo,proto3" json:"foo,omitempty"`
|
|
Bar uint64 `protobuf:"varint,2,opt,name=bar,proto3" json:"bar,omitempty"`
|
|
XXX_NoUnkeyedLiteral struct{} `json:"-"`
|
|
XXX_unrecognized []byte `json:"-"`
|
|
XXX_sizecache int32 `json:"-"`
|
|
}
|
|
|
|
func (m *TestSimpleMessage) Reset() { *m = TestSimpleMessage{} }
|
|
func (m *TestSimpleMessage) String() string { return proto.CompactTextString(m) }
|
|
func (*TestSimpleMessage) ProtoMessage() {}
|
|
func (*TestSimpleMessage) Descriptor() ([]byte, []int) {
|
|
return fileDescriptor_1f902154cb7707ef, []int{5}
|
|
}
|
|
func (m *TestSimpleMessage) XXX_Unmarshal(b []byte) error {
|
|
return m.Unmarshal(b)
|
|
}
|
|
func (m *TestSimpleMessage) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
|
|
if deterministic {
|
|
return xxx_messageInfo_TestSimpleMessage.Marshal(b, m, deterministic)
|
|
} else {
|
|
b = b[:cap(b)]
|
|
n, err := m.MarshalToSizedBuffer(b)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return b[:n], nil
|
|
}
|
|
}
|
|
func (m *TestSimpleMessage) XXX_Merge(src proto.Message) {
|
|
xxx_messageInfo_TestSimpleMessage.Merge(m, src)
|
|
}
|
|
func (m *TestSimpleMessage) XXX_Size() int {
|
|
return m.Size()
|
|
}
|
|
func (m *TestSimpleMessage) XXX_DiscardUnknown() {
|
|
xxx_messageInfo_TestSimpleMessage.DiscardUnknown(m)
|
|
}
|
|
|
|
var xxx_messageInfo_TestSimpleMessage proto.InternalMessageInfo
|
|
|
|
func (m *TestSimpleMessage) GetFoo() []byte {
|
|
if m != nil {
|
|
return m.Foo
|
|
}
|
|
return nil
|
|
}
|
|
|
|
func (m *TestSimpleMessage) GetBar() uint64 {
|
|
if m != nil {
|
|
return m.Bar
|
|
}
|
|
return 0
|
|
}
|
|
|
|
func init() {
|
|
proto.RegisterEnum("testing.Person_PhoneType", Person_PhoneType_name, Person_PhoneType_value)
|
|
proto.RegisterType((*TestMessage)(nil), "testing.TestMessage")
|
|
proto.RegisterType((*TestNestedMessage)(nil), "testing.TestNestedMessage")
|
|
proto.RegisterType((*Puzzle)(nil), "testing.Puzzle")
|
|
proto.RegisterType((*Person)(nil), "testing.Person")
|
|
proto.RegisterType((*Person_PhoneNumber)(nil), "testing.Person.PhoneNumber")
|
|
proto.RegisterType((*AddressBook)(nil), "testing.AddressBook")
|
|
proto.RegisterType((*TestSimpleMessage)(nil), "testing.TestSimpleMessage")
|
|
}
|
|
|
|
func init() { proto.RegisterFile("proto/testing/test.proto", fileDescriptor_1f902154cb7707ef) }
|
|
|
|
var fileDescriptor_1f902154cb7707ef = []byte{
|
|
// 500 bytes of a gzipped FileDescriptorProto
|
|
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x6c, 0x52, 0xed, 0x8a, 0xd3, 0x40,
|
|
0x14, 0x35, 0xfd, 0x88, 0xf6, 0xa6, 0xac, 0x75, 0x58, 0x24, 0x76, 0xa5, 0x2d, 0xf3, 0x43, 0x17,
|
|
0xa4, 0x29, 0x76, 0x41, 0x61, 0x41, 0xc1, 0xc2, 0x82, 0xa2, 0xdd, 0x96, 0xb1, 0xe2, 0x4f, 0x49,
|
|
0x9a, 0xdb, 0x34, 0x98, 0x64, 0x42, 0x66, 0x82, 0x6c, 0xde, 0xcc, 0x37, 0xf0, 0xa7, 0x4f, 0x20,
|
|
0xd2, 0x47, 0xf0, 0x09, 0x64, 0x26, 0xd3, 0xed, 0xb2, 0xec, 0xaf, 0x9c, 0x7b, 0xe6, 0xe4, 0xcc,
|
|
0xb9, 0x73, 0x2f, 0xb8, 0x79, 0xc1, 0x25, 0x9f, 0x48, 0x14, 0x32, 0xce, 0x22, 0xfd, 0xf5, 0x34,
|
|
0x45, 0xee, 0x1b, 0xae, 0x3f, 0x8c, 0x38, 0x8f, 0x12, 0x9c, 0x68, 0x3a, 0x28, 0x37, 0x13, 0x19,
|
|
0xa7, 0x28, 0xa4, 0x9f, 0xe6, 0xb5, 0xb2, 0x3f, 0x8e, 0x62, 0xb9, 0x2d, 0x03, 0x6f, 0xcd, 0xd3,
|
|
0x49, 0xc4, 0x23, 0x7e, 0x50, 0xaa, 0xaa, 0xbe, 0x40, 0xa1, 0x5a, 0x4e, 0x19, 0x38, 0x2b, 0x14,
|
|
0x72, 0x8e, 0x42, 0xf8, 0x11, 0x92, 0x1e, 0x34, 0x37, 0x9c, 0xbb, 0xd6, 0xc8, 0x3a, 0xed, 0x30,
|
|
0x05, 0xc9, 0x4b, 0x68, 0x06, 0x7e, 0xe1, 0x36, 0x14, 0x33, 0x1b, 0xfe, 0xfb, 0x33, 0x3c, 0xd9,
|
|
0xc4, 0x55, 0x75, 0x4e, 0x83, 0xb2, 0xaa, 0xe8, 0x48, 0xe4, 0xb8, 0x1e, 0x67, 0x7e, 0x8a, 0xe7,
|
|
0x34, 0xf0, 0x2b, 0xca, 0x94, 0x96, 0x2e, 0xe0, 0x91, 0xf2, 0xbc, 0x44, 0x21, 0x31, 0xdc, 0x3b,
|
|
0x13, 0x68, 0x6d, 0xca, 0xaa, 0x32, 0xd6, 0x1a, 0x93, 0x67, 0xd0, 0x4c, 0x45, 0xa4, 0xbd, 0x9d,
|
|
0xe9, 0xb1, 0x67, 0x7a, 0xf4, 0x6e, 0x04, 0x62, 0x4a, 0x40, 0xdf, 0x82, 0xbd, 0x2c, 0xab, 0x2a,
|
|
0x41, 0xf2, 0x14, 0x3a, 0xeb, 0xad, 0x9f, 0x24, 0x98, 0x45, 0x68, 0xac, 0x0e, 0x04, 0x79, 0x0c,
|
|
0xb6, 0x9f, 0x89, 0x1f, 0x68, 0xe2, 0x32, 0x53, 0xd1, 0x9f, 0x0d, 0xb0, 0x97, 0x58, 0x08, 0x9e,
|
|
0xa9, 0x18, 0x2a, 0xee, 0x3e, 0x86, 0xc2, 0xe4, 0x08, 0x1a, 0x71, 0xa8, 0x7f, 0x69, 0xb3, 0x46,
|
|
0x1c, 0x92, 0x63, 0x68, 0x63, 0xea, 0xc7, 0x89, 0xdb, 0xd4, 0xa2, 0xba, 0x20, 0x67, 0x60, 0xe7,
|
|
0x5b, 0x9e, 0xa1, 0x70, 0x5b, 0xa3, 0xe6, 0xa9, 0x33, 0x3d, 0xb9, 0xce, 0x5b, 0x5b, 0x7b, 0x4b,
|
|
0x75, 0x7a, 0x59, 0xa6, 0x01, 0x16, 0xcc, 0x48, 0xc9, 0x1b, 0xe8, 0x26, 0xbe, 0x90, 0xdf, 0xca,
|
|
0x3c, 0xf4, 0x25, 0x86, 0x6e, 0x5b, 0xb7, 0xda, 0xf7, 0xea, 0x29, 0x7a, 0xfb, 0xd9, 0x78, 0xab,
|
|
0xfd, 0x14, 0x99, 0xa3, 0xf4, 0x5f, 0x6a, 0x79, 0x7f, 0x05, 0xce, 0x0d, 0x57, 0xd5, 0x5f, 0xa6,
|
|
0x91, 0x89, 0x6f, 0x2a, 0x32, 0x86, 0x96, 0xbc, 0xca, 0x51, 0xb7, 0x70, 0x34, 0x7d, 0x72, 0x67,
|
|
0xb0, 0xd5, 0x55, 0x8e, 0x4c, 0xcb, 0xe8, 0x0b, 0xe8, 0x5c, 0x53, 0x04, 0xc0, 0x9e, 0x2f, 0x66,
|
|
0x1f, 0x3e, 0x5d, 0xf4, 0xee, 0x91, 0x07, 0xd0, 0x7a, 0xbf, 0x98, 0x5f, 0xf4, 0x2c, 0x85, 0xbe,
|
|
0x2e, 0xd8, 0xc7, 0x5e, 0x83, 0xbe, 0x02, 0xe7, 0x5d, 0x18, 0x16, 0x28, 0xc4, 0x8c, 0xf3, 0xef,
|
|
0xe4, 0x39, 0xd8, 0x39, 0xf2, 0x3c, 0x51, 0x2f, 0xa8, 0x5e, 0xe1, 0xe1, 0xad, 0xcb, 0x98, 0x39,
|
|
0xa6, 0xaf, 0xeb, 0x25, 0xf8, 0x1c, 0xa7, 0x79, 0x82, 0x77, 0xac, 0x57, 0xb7, 0x5e, 0xaf, 0xde,
|
|
0x61, 0xbd, 0x5a, 0x7a, 0x7b, 0x66, 0xdd, 0x5f, 0xbb, 0x81, 0xf5, 0x7b, 0x37, 0xb0, 0xfe, 0xee,
|
|
0x06, 0x56, 0x60, 0xeb, 0x27, 0x3a, 0xfb, 0x1f, 0x00, 0x00, 0xff, 0xff, 0x27, 0xce, 0x0c, 0x3c,
|
|
0x1b, 0x03, 0x00, 0x00,
|
|
}
|
|
|
|
func (m *TestMessage) Marshal() (dAtA []byte, err error) {
|
|
size := m.Size()
|
|
dAtA = make([]byte, size)
|
|
n, err := m.MarshalToSizedBuffer(dAtA[:size])
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return dAtA[:n], nil
|
|
}
|
|
|
|
func (m *TestMessage) MarshalTo(dAtA []byte) (int, error) {
|
|
size := m.Size()
|
|
return m.MarshalToSizedBuffer(dAtA[:size])
|
|
}
|
|
|
|
func (m *TestMessage) MarshalToSizedBuffer(dAtA []byte) (int, error) {
|
|
i := len(dAtA)
|
|
_ = i
|
|
var l int
|
|
_ = l
|
|
if m.XXX_unrecognized != nil {
|
|
i -= len(m.XXX_unrecognized)
|
|
copy(dAtA[i:], m.XXX_unrecognized)
|
|
}
|
|
if len(m.Bar) > 0 {
|
|
i -= len(m.Bar)
|
|
copy(dAtA[i:], m.Bar)
|
|
i = encodeVarintTest(dAtA, i, uint64(len(m.Bar)))
|
|
i--
|
|
dAtA[i] = 0x12
|
|
}
|
|
if len(m.Foo) > 0 {
|
|
i -= len(m.Foo)
|
|
copy(dAtA[i:], m.Foo)
|
|
i = encodeVarintTest(dAtA, i, uint64(len(m.Foo)))
|
|
i--
|
|
dAtA[i] = 0xa
|
|
}
|
|
return len(dAtA) - i, nil
|
|
}
|
|
|
|
func (m *TestNestedMessage) Marshal() (dAtA []byte, err error) {
|
|
size := m.Size()
|
|
dAtA = make([]byte, size)
|
|
n, err := m.MarshalToSizedBuffer(dAtA[:size])
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return dAtA[:n], nil
|
|
}
|
|
|
|
func (m *TestNestedMessage) MarshalTo(dAtA []byte) (int, error) {
|
|
size := m.Size()
|
|
return m.MarshalToSizedBuffer(dAtA[:size])
|
|
}
|
|
|
|
func (m *TestNestedMessage) MarshalToSizedBuffer(dAtA []byte) (int, error) {
|
|
i := len(dAtA)
|
|
_ = i
|
|
var l int
|
|
_ = l
|
|
if m.XXX_unrecognized != nil {
|
|
i -= len(m.XXX_unrecognized)
|
|
copy(dAtA[i:], m.XXX_unrecognized)
|
|
}
|
|
if m.Msg != nil {
|
|
{
|
|
size, err := m.Msg.MarshalToSizedBuffer(dAtA[:i])
|
|
if err != nil {
|
|
return 0, err
|
|
}
|
|
i -= size
|
|
i = encodeVarintTest(dAtA, i, uint64(size))
|
|
}
|
|
i--
|
|
dAtA[i] = 0x12
|
|
}
|
|
if len(m.Fuzz) > 0 {
|
|
i -= len(m.Fuzz)
|
|
copy(dAtA[i:], m.Fuzz)
|
|
i = encodeVarintTest(dAtA, i, uint64(len(m.Fuzz)))
|
|
i--
|
|
dAtA[i] = 0xa
|
|
}
|
|
return len(dAtA) - i, nil
|
|
}
|
|
|
|
func (m *Puzzle) Marshal() (dAtA []byte, err error) {
|
|
size := m.Size()
|
|
dAtA = make([]byte, size)
|
|
n, err := m.MarshalToSizedBuffer(dAtA[:size])
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return dAtA[:n], nil
|
|
}
|
|
|
|
func (m *Puzzle) MarshalTo(dAtA []byte) (int, error) {
|
|
size := m.Size()
|
|
return m.MarshalToSizedBuffer(dAtA[:size])
|
|
}
|
|
|
|
func (m *Puzzle) MarshalToSizedBuffer(dAtA []byte) (int, error) {
|
|
i := len(dAtA)
|
|
_ = i
|
|
var l int
|
|
_ = l
|
|
if m.XXX_unrecognized != nil {
|
|
i -= len(m.XXX_unrecognized)
|
|
copy(dAtA[i:], m.XXX_unrecognized)
|
|
}
|
|
if len(m.Answer) > 0 {
|
|
i -= len(m.Answer)
|
|
copy(dAtA[i:], m.Answer)
|
|
i = encodeVarintTest(dAtA, i, uint64(len(m.Answer)))
|
|
i--
|
|
dAtA[i] = 0x12
|
|
}
|
|
if len(m.Challenge) > 0 {
|
|
i -= len(m.Challenge)
|
|
copy(dAtA[i:], m.Challenge)
|
|
i = encodeVarintTest(dAtA, i, uint64(len(m.Challenge)))
|
|
i--
|
|
dAtA[i] = 0xa
|
|
}
|
|
return len(dAtA) - i, nil
|
|
}
|
|
|
|
func (m *Person) Marshal() (dAtA []byte, err error) {
|
|
size := m.Size()
|
|
dAtA = make([]byte, size)
|
|
n, err := m.MarshalToSizedBuffer(dAtA[:size])
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return dAtA[:n], nil
|
|
}
|
|
|
|
func (m *Person) MarshalTo(dAtA []byte) (int, error) {
|
|
size := m.Size()
|
|
return m.MarshalToSizedBuffer(dAtA[:size])
|
|
}
|
|
|
|
func (m *Person) MarshalToSizedBuffer(dAtA []byte) (int, error) {
|
|
i := len(dAtA)
|
|
_ = i
|
|
var l int
|
|
_ = l
|
|
if m.XXX_unrecognized != nil {
|
|
i -= len(m.XXX_unrecognized)
|
|
copy(dAtA[i:], m.XXX_unrecognized)
|
|
}
|
|
if m.LastUpdated != nil {
|
|
{
|
|
size, err := m.LastUpdated.MarshalToSizedBuffer(dAtA[:i])
|
|
if err != nil {
|
|
return 0, err
|
|
}
|
|
i -= size
|
|
i = encodeVarintTest(dAtA, i, uint64(size))
|
|
}
|
|
i--
|
|
dAtA[i] = 0x2a
|
|
}
|
|
if len(m.Phones) > 0 {
|
|
for iNdEx := len(m.Phones) - 1; iNdEx >= 0; iNdEx-- {
|
|
{
|
|
size, err := m.Phones[iNdEx].MarshalToSizedBuffer(dAtA[:i])
|
|
if err != nil {
|
|
return 0, err
|
|
}
|
|
i -= size
|
|
i = encodeVarintTest(dAtA, i, uint64(size))
|
|
}
|
|
i--
|
|
dAtA[i] = 0x22
|
|
}
|
|
}
|
|
if len(m.Email) > 0 {
|
|
i -= len(m.Email)
|
|
copy(dAtA[i:], m.Email)
|
|
i = encodeVarintTest(dAtA, i, uint64(len(m.Email)))
|
|
i--
|
|
dAtA[i] = 0x1a
|
|
}
|
|
if m.Id != 0 {
|
|
i = encodeVarintTest(dAtA, i, uint64(m.Id))
|
|
i--
|
|
dAtA[i] = 0x10
|
|
}
|
|
if len(m.Name) > 0 {
|
|
i -= len(m.Name)
|
|
copy(dAtA[i:], m.Name)
|
|
i = encodeVarintTest(dAtA, i, uint64(len(m.Name)))
|
|
i--
|
|
dAtA[i] = 0xa
|
|
}
|
|
return len(dAtA) - i, nil
|
|
}
|
|
|
|
func (m *Person_PhoneNumber) Marshal() (dAtA []byte, err error) {
|
|
size := m.Size()
|
|
dAtA = make([]byte, size)
|
|
n, err := m.MarshalToSizedBuffer(dAtA[:size])
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return dAtA[:n], nil
|
|
}
|
|
|
|
func (m *Person_PhoneNumber) MarshalTo(dAtA []byte) (int, error) {
|
|
size := m.Size()
|
|
return m.MarshalToSizedBuffer(dAtA[:size])
|
|
}
|
|
|
|
func (m *Person_PhoneNumber) MarshalToSizedBuffer(dAtA []byte) (int, error) {
|
|
i := len(dAtA)
|
|
_ = i
|
|
var l int
|
|
_ = l
|
|
if m.XXX_unrecognized != nil {
|
|
i -= len(m.XXX_unrecognized)
|
|
copy(dAtA[i:], m.XXX_unrecognized)
|
|
}
|
|
if m.Type != 0 {
|
|
i = encodeVarintTest(dAtA, i, uint64(m.Type))
|
|
i--
|
|
dAtA[i] = 0x10
|
|
}
|
|
if len(m.Number) > 0 {
|
|
i -= len(m.Number)
|
|
copy(dAtA[i:], m.Number)
|
|
i = encodeVarintTest(dAtA, i, uint64(len(m.Number)))
|
|
i--
|
|
dAtA[i] = 0xa
|
|
}
|
|
return len(dAtA) - i, nil
|
|
}
|
|
|
|
func (m *AddressBook) Marshal() (dAtA []byte, err error) {
|
|
size := m.Size()
|
|
dAtA = make([]byte, size)
|
|
n, err := m.MarshalToSizedBuffer(dAtA[:size])
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return dAtA[:n], nil
|
|
}
|
|
|
|
func (m *AddressBook) MarshalTo(dAtA []byte) (int, error) {
|
|
size := m.Size()
|
|
return m.MarshalToSizedBuffer(dAtA[:size])
|
|
}
|
|
|
|
func (m *AddressBook) MarshalToSizedBuffer(dAtA []byte) (int, error) {
|
|
i := len(dAtA)
|
|
_ = i
|
|
var l int
|
|
_ = l
|
|
if m.XXX_unrecognized != nil {
|
|
i -= len(m.XXX_unrecognized)
|
|
copy(dAtA[i:], m.XXX_unrecognized)
|
|
}
|
|
if len(m.People) > 0 {
|
|
for iNdEx := len(m.People) - 1; iNdEx >= 0; iNdEx-- {
|
|
{
|
|
size, err := m.People[iNdEx].MarshalToSizedBuffer(dAtA[:i])
|
|
if err != nil {
|
|
return 0, err
|
|
}
|
|
i -= size
|
|
i = encodeVarintTest(dAtA, i, uint64(size))
|
|
}
|
|
i--
|
|
dAtA[i] = 0xa
|
|
}
|
|
}
|
|
return len(dAtA) - i, nil
|
|
}
|
|
|
|
func (m *TestSimpleMessage) Marshal() (dAtA []byte, err error) {
|
|
size := m.Size()
|
|
dAtA = make([]byte, size)
|
|
n, err := m.MarshalToSizedBuffer(dAtA[:size])
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return dAtA[:n], nil
|
|
}
|
|
|
|
func (m *TestSimpleMessage) MarshalTo(dAtA []byte) (int, error) {
|
|
size := m.Size()
|
|
return m.MarshalToSizedBuffer(dAtA[:size])
|
|
}
|
|
|
|
func (m *TestSimpleMessage) MarshalToSizedBuffer(dAtA []byte) (int, error) {
|
|
i := len(dAtA)
|
|
_ = i
|
|
var l int
|
|
_ = l
|
|
if m.XXX_unrecognized != nil {
|
|
i -= len(m.XXX_unrecognized)
|
|
copy(dAtA[i:], m.XXX_unrecognized)
|
|
}
|
|
if m.Bar != 0 {
|
|
i = encodeVarintTest(dAtA, i, uint64(m.Bar))
|
|
i--
|
|
dAtA[i] = 0x10
|
|
}
|
|
if len(m.Foo) > 0 {
|
|
i -= len(m.Foo)
|
|
copy(dAtA[i:], m.Foo)
|
|
i = encodeVarintTest(dAtA, i, uint64(len(m.Foo)))
|
|
i--
|
|
dAtA[i] = 0xa
|
|
}
|
|
return len(dAtA) - i, nil
|
|
}
|
|
|
|
func encodeVarintTest(dAtA []byte, offset int, v uint64) int {
|
|
offset -= sovTest(v)
|
|
base := offset
|
|
for v >= 1<<7 {
|
|
dAtA[offset] = uint8(v&0x7f | 0x80)
|
|
v >>= 7
|
|
offset++
|
|
}
|
|
dAtA[offset] = uint8(v)
|
|
return base
|
|
}
|
|
func (m *TestMessage) Size() (n int) {
|
|
if m == nil {
|
|
return 0
|
|
}
|
|
var l int
|
|
_ = l
|
|
l = len(m.Foo)
|
|
if l > 0 {
|
|
n += 1 + l + sovTest(uint64(l))
|
|
}
|
|
l = len(m.Bar)
|
|
if l > 0 {
|
|
n += 1 + l + sovTest(uint64(l))
|
|
}
|
|
if m.XXX_unrecognized != nil {
|
|
n += len(m.XXX_unrecognized)
|
|
}
|
|
return n
|
|
}
|
|
|
|
func (m *TestNestedMessage) Size() (n int) {
|
|
if m == nil {
|
|
return 0
|
|
}
|
|
var l int
|
|
_ = l
|
|
l = len(m.Fuzz)
|
|
if l > 0 {
|
|
n += 1 + l + sovTest(uint64(l))
|
|
}
|
|
if m.Msg != nil {
|
|
l = m.Msg.Size()
|
|
n += 1 + l + sovTest(uint64(l))
|
|
}
|
|
if m.XXX_unrecognized != nil {
|
|
n += len(m.XXX_unrecognized)
|
|
}
|
|
return n
|
|
}
|
|
|
|
func (m *Puzzle) Size() (n int) {
|
|
if m == nil {
|
|
return 0
|
|
}
|
|
var l int
|
|
_ = l
|
|
l = len(m.Challenge)
|
|
if l > 0 {
|
|
n += 1 + l + sovTest(uint64(l))
|
|
}
|
|
l = len(m.Answer)
|
|
if l > 0 {
|
|
n += 1 + l + sovTest(uint64(l))
|
|
}
|
|
if m.XXX_unrecognized != nil {
|
|
n += len(m.XXX_unrecognized)
|
|
}
|
|
return n
|
|
}
|
|
|
|
func (m *Person) Size() (n int) {
|
|
if m == nil {
|
|
return 0
|
|
}
|
|
var l int
|
|
_ = l
|
|
l = len(m.Name)
|
|
if l > 0 {
|
|
n += 1 + l + sovTest(uint64(l))
|
|
}
|
|
if m.Id != 0 {
|
|
n += 1 + sovTest(uint64(m.Id))
|
|
}
|
|
l = len(m.Email)
|
|
if l > 0 {
|
|
n += 1 + l + sovTest(uint64(l))
|
|
}
|
|
if len(m.Phones) > 0 {
|
|
for _, e := range m.Phones {
|
|
l = e.Size()
|
|
n += 1 + l + sovTest(uint64(l))
|
|
}
|
|
}
|
|
if m.LastUpdated != nil {
|
|
l = m.LastUpdated.Size()
|
|
n += 1 + l + sovTest(uint64(l))
|
|
}
|
|
if m.XXX_unrecognized != nil {
|
|
n += len(m.XXX_unrecognized)
|
|
}
|
|
return n
|
|
}
|
|
|
|
func (m *Person_PhoneNumber) Size() (n int) {
|
|
if m == nil {
|
|
return 0
|
|
}
|
|
var l int
|
|
_ = l
|
|
l = len(m.Number)
|
|
if l > 0 {
|
|
n += 1 + l + sovTest(uint64(l))
|
|
}
|
|
if m.Type != 0 {
|
|
n += 1 + sovTest(uint64(m.Type))
|
|
}
|
|
if m.XXX_unrecognized != nil {
|
|
n += len(m.XXX_unrecognized)
|
|
}
|
|
return n
|
|
}
|
|
|
|
func (m *AddressBook) Size() (n int) {
|
|
if m == nil {
|
|
return 0
|
|
}
|
|
var l int
|
|
_ = l
|
|
if len(m.People) > 0 {
|
|
for _, e := range m.People {
|
|
l = e.Size()
|
|
n += 1 + l + sovTest(uint64(l))
|
|
}
|
|
}
|
|
if m.XXX_unrecognized != nil {
|
|
n += len(m.XXX_unrecognized)
|
|
}
|
|
return n
|
|
}
|
|
|
|
func (m *TestSimpleMessage) Size() (n int) {
|
|
if m == nil {
|
|
return 0
|
|
}
|
|
var l int
|
|
_ = l
|
|
l = len(m.Foo)
|
|
if l > 0 {
|
|
n += 1 + l + sovTest(uint64(l))
|
|
}
|
|
if m.Bar != 0 {
|
|
n += 1 + sovTest(uint64(m.Bar))
|
|
}
|
|
if m.XXX_unrecognized != nil {
|
|
n += len(m.XXX_unrecognized)
|
|
}
|
|
return n
|
|
}
|
|
|
|
func sovTest(x uint64) (n int) {
|
|
return (math_bits.Len64(x|1) + 6) / 7
|
|
}
|
|
func sozTest(x uint64) (n int) {
|
|
return sovTest(uint64((x << 1) ^ uint64((int64(x) >> 63))))
|
|
}
|
|
func (m *TestMessage) Unmarshal(dAtA []byte) error {
|
|
l := len(dAtA)
|
|
iNdEx := 0
|
|
for iNdEx < l {
|
|
preIndex := iNdEx
|
|
var wire uint64
|
|
for shift := uint(0); ; shift += 7 {
|
|
if shift >= 64 {
|
|
return ErrIntOverflowTest
|
|
}
|
|
if iNdEx >= l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
b := dAtA[iNdEx]
|
|
iNdEx++
|
|
wire |= uint64(b&0x7F) << shift
|
|
if b < 0x80 {
|
|
break
|
|
}
|
|
}
|
|
fieldNum := int32(wire >> 3)
|
|
wireType := int(wire & 0x7)
|
|
if wireType == 4 {
|
|
return fmt.Errorf("proto: TestMessage: wiretype end group for non-group")
|
|
}
|
|
if fieldNum <= 0 {
|
|
return fmt.Errorf("proto: TestMessage: illegal tag %d (wire type %d)", fieldNum, wire)
|
|
}
|
|
switch fieldNum {
|
|
case 1:
|
|
if wireType != 2 {
|
|
return fmt.Errorf("proto: wrong wireType = %d for field Foo", wireType)
|
|
}
|
|
var stringLen uint64
|
|
for shift := uint(0); ; shift += 7 {
|
|
if shift >= 64 {
|
|
return ErrIntOverflowTest
|
|
}
|
|
if iNdEx >= l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
b := dAtA[iNdEx]
|
|
iNdEx++
|
|
stringLen |= uint64(b&0x7F) << shift
|
|
if b < 0x80 {
|
|
break
|
|
}
|
|
}
|
|
intStringLen := int(stringLen)
|
|
if intStringLen < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
postIndex := iNdEx + intStringLen
|
|
if postIndex < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
if postIndex > l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
m.Foo = string(dAtA[iNdEx:postIndex])
|
|
iNdEx = postIndex
|
|
case 2:
|
|
if wireType != 2 {
|
|
return fmt.Errorf("proto: wrong wireType = %d for field Bar", wireType)
|
|
}
|
|
var stringLen uint64
|
|
for shift := uint(0); ; shift += 7 {
|
|
if shift >= 64 {
|
|
return ErrIntOverflowTest
|
|
}
|
|
if iNdEx >= l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
b := dAtA[iNdEx]
|
|
iNdEx++
|
|
stringLen |= uint64(b&0x7F) << shift
|
|
if b < 0x80 {
|
|
break
|
|
}
|
|
}
|
|
intStringLen := int(stringLen)
|
|
if intStringLen < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
postIndex := iNdEx + intStringLen
|
|
if postIndex < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
if postIndex > l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
m.Bar = string(dAtA[iNdEx:postIndex])
|
|
iNdEx = postIndex
|
|
default:
|
|
iNdEx = preIndex
|
|
skippy, err := skipTest(dAtA[iNdEx:])
|
|
if err != nil {
|
|
return err
|
|
}
|
|
if skippy < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
if (iNdEx + skippy) < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
if (iNdEx + skippy) > l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
|
|
iNdEx += skippy
|
|
}
|
|
}
|
|
|
|
if iNdEx > l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
return nil
|
|
}
|
|
func (m *TestNestedMessage) Unmarshal(dAtA []byte) error {
|
|
l := len(dAtA)
|
|
iNdEx := 0
|
|
for iNdEx < l {
|
|
preIndex := iNdEx
|
|
var wire uint64
|
|
for shift := uint(0); ; shift += 7 {
|
|
if shift >= 64 {
|
|
return ErrIntOverflowTest
|
|
}
|
|
if iNdEx >= l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
b := dAtA[iNdEx]
|
|
iNdEx++
|
|
wire |= uint64(b&0x7F) << shift
|
|
if b < 0x80 {
|
|
break
|
|
}
|
|
}
|
|
fieldNum := int32(wire >> 3)
|
|
wireType := int(wire & 0x7)
|
|
if wireType == 4 {
|
|
return fmt.Errorf("proto: TestNestedMessage: wiretype end group for non-group")
|
|
}
|
|
if fieldNum <= 0 {
|
|
return fmt.Errorf("proto: TestNestedMessage: illegal tag %d (wire type %d)", fieldNum, wire)
|
|
}
|
|
switch fieldNum {
|
|
case 1:
|
|
if wireType != 2 {
|
|
return fmt.Errorf("proto: wrong wireType = %d for field Fuzz", wireType)
|
|
}
|
|
var stringLen uint64
|
|
for shift := uint(0); ; shift += 7 {
|
|
if shift >= 64 {
|
|
return ErrIntOverflowTest
|
|
}
|
|
if iNdEx >= l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
b := dAtA[iNdEx]
|
|
iNdEx++
|
|
stringLen |= uint64(b&0x7F) << shift
|
|
if b < 0x80 {
|
|
break
|
|
}
|
|
}
|
|
intStringLen := int(stringLen)
|
|
if intStringLen < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
postIndex := iNdEx + intStringLen
|
|
if postIndex < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
if postIndex > l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
m.Fuzz = string(dAtA[iNdEx:postIndex])
|
|
iNdEx = postIndex
|
|
case 2:
|
|
if wireType != 2 {
|
|
return fmt.Errorf("proto: wrong wireType = %d for field Msg", wireType)
|
|
}
|
|
var msglen int
|
|
for shift := uint(0); ; shift += 7 {
|
|
if shift >= 64 {
|
|
return ErrIntOverflowTest
|
|
}
|
|
if iNdEx >= l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
b := dAtA[iNdEx]
|
|
iNdEx++
|
|
msglen |= int(b&0x7F) << shift
|
|
if b < 0x80 {
|
|
break
|
|
}
|
|
}
|
|
if msglen < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
postIndex := iNdEx + msglen
|
|
if postIndex < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
if postIndex > l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
if m.Msg == nil {
|
|
m.Msg = &TestMessage{}
|
|
}
|
|
if err := m.Msg.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
|
|
return err
|
|
}
|
|
iNdEx = postIndex
|
|
default:
|
|
iNdEx = preIndex
|
|
skippy, err := skipTest(dAtA[iNdEx:])
|
|
if err != nil {
|
|
return err
|
|
}
|
|
if skippy < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
if (iNdEx + skippy) < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
if (iNdEx + skippy) > l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
|
|
iNdEx += skippy
|
|
}
|
|
}
|
|
|
|
if iNdEx > l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
return nil
|
|
}
|
|
func (m *Puzzle) Unmarshal(dAtA []byte) error {
|
|
l := len(dAtA)
|
|
iNdEx := 0
|
|
for iNdEx < l {
|
|
preIndex := iNdEx
|
|
var wire uint64
|
|
for shift := uint(0); ; shift += 7 {
|
|
if shift >= 64 {
|
|
return ErrIntOverflowTest
|
|
}
|
|
if iNdEx >= l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
b := dAtA[iNdEx]
|
|
iNdEx++
|
|
wire |= uint64(b&0x7F) << shift
|
|
if b < 0x80 {
|
|
break
|
|
}
|
|
}
|
|
fieldNum := int32(wire >> 3)
|
|
wireType := int(wire & 0x7)
|
|
if wireType == 4 {
|
|
return fmt.Errorf("proto: Puzzle: wiretype end group for non-group")
|
|
}
|
|
if fieldNum <= 0 {
|
|
return fmt.Errorf("proto: Puzzle: illegal tag %d (wire type %d)", fieldNum, wire)
|
|
}
|
|
switch fieldNum {
|
|
case 1:
|
|
if wireType != 2 {
|
|
return fmt.Errorf("proto: wrong wireType = %d for field Challenge", wireType)
|
|
}
|
|
var stringLen uint64
|
|
for shift := uint(0); ; shift += 7 {
|
|
if shift >= 64 {
|
|
return ErrIntOverflowTest
|
|
}
|
|
if iNdEx >= l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
b := dAtA[iNdEx]
|
|
iNdEx++
|
|
stringLen |= uint64(b&0x7F) << shift
|
|
if b < 0x80 {
|
|
break
|
|
}
|
|
}
|
|
intStringLen := int(stringLen)
|
|
if intStringLen < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
postIndex := iNdEx + intStringLen
|
|
if postIndex < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
if postIndex > l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
m.Challenge = string(dAtA[iNdEx:postIndex])
|
|
iNdEx = postIndex
|
|
case 2:
|
|
if wireType != 2 {
|
|
return fmt.Errorf("proto: wrong wireType = %d for field Answer", wireType)
|
|
}
|
|
var stringLen uint64
|
|
for shift := uint(0); ; shift += 7 {
|
|
if shift >= 64 {
|
|
return ErrIntOverflowTest
|
|
}
|
|
if iNdEx >= l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
b := dAtA[iNdEx]
|
|
iNdEx++
|
|
stringLen |= uint64(b&0x7F) << shift
|
|
if b < 0x80 {
|
|
break
|
|
}
|
|
}
|
|
intStringLen := int(stringLen)
|
|
if intStringLen < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
postIndex := iNdEx + intStringLen
|
|
if postIndex < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
if postIndex > l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
m.Answer = string(dAtA[iNdEx:postIndex])
|
|
iNdEx = postIndex
|
|
default:
|
|
iNdEx = preIndex
|
|
skippy, err := skipTest(dAtA[iNdEx:])
|
|
if err != nil {
|
|
return err
|
|
}
|
|
if skippy < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
if (iNdEx + skippy) < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
if (iNdEx + skippy) > l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
|
|
iNdEx += skippy
|
|
}
|
|
}
|
|
|
|
if iNdEx > l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
return nil
|
|
}
|
|
func (m *Person) Unmarshal(dAtA []byte) error {
|
|
l := len(dAtA)
|
|
iNdEx := 0
|
|
for iNdEx < l {
|
|
preIndex := iNdEx
|
|
var wire uint64
|
|
for shift := uint(0); ; shift += 7 {
|
|
if shift >= 64 {
|
|
return ErrIntOverflowTest
|
|
}
|
|
if iNdEx >= l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
b := dAtA[iNdEx]
|
|
iNdEx++
|
|
wire |= uint64(b&0x7F) << shift
|
|
if b < 0x80 {
|
|
break
|
|
}
|
|
}
|
|
fieldNum := int32(wire >> 3)
|
|
wireType := int(wire & 0x7)
|
|
if wireType == 4 {
|
|
return fmt.Errorf("proto: Person: wiretype end group for non-group")
|
|
}
|
|
if fieldNum <= 0 {
|
|
return fmt.Errorf("proto: Person: illegal tag %d (wire type %d)", fieldNum, wire)
|
|
}
|
|
switch fieldNum {
|
|
case 1:
|
|
if wireType != 2 {
|
|
return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType)
|
|
}
|
|
var stringLen uint64
|
|
for shift := uint(0); ; shift += 7 {
|
|
if shift >= 64 {
|
|
return ErrIntOverflowTest
|
|
}
|
|
if iNdEx >= l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
b := dAtA[iNdEx]
|
|
iNdEx++
|
|
stringLen |= uint64(b&0x7F) << shift
|
|
if b < 0x80 {
|
|
break
|
|
}
|
|
}
|
|
intStringLen := int(stringLen)
|
|
if intStringLen < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
postIndex := iNdEx + intStringLen
|
|
if postIndex < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
if postIndex > l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
m.Name = string(dAtA[iNdEx:postIndex])
|
|
iNdEx = postIndex
|
|
case 2:
|
|
if wireType != 0 {
|
|
return fmt.Errorf("proto: wrong wireType = %d for field Id", wireType)
|
|
}
|
|
m.Id = 0
|
|
for shift := uint(0); ; shift += 7 {
|
|
if shift >= 64 {
|
|
return ErrIntOverflowTest
|
|
}
|
|
if iNdEx >= l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
b := dAtA[iNdEx]
|
|
iNdEx++
|
|
m.Id |= int32(b&0x7F) << shift
|
|
if b < 0x80 {
|
|
break
|
|
}
|
|
}
|
|
case 3:
|
|
if wireType != 2 {
|
|
return fmt.Errorf("proto: wrong wireType = %d for field Email", wireType)
|
|
}
|
|
var stringLen uint64
|
|
for shift := uint(0); ; shift += 7 {
|
|
if shift >= 64 {
|
|
return ErrIntOverflowTest
|
|
}
|
|
if iNdEx >= l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
b := dAtA[iNdEx]
|
|
iNdEx++
|
|
stringLen |= uint64(b&0x7F) << shift
|
|
if b < 0x80 {
|
|
break
|
|
}
|
|
}
|
|
intStringLen := int(stringLen)
|
|
if intStringLen < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
postIndex := iNdEx + intStringLen
|
|
if postIndex < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
if postIndex > l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
m.Email = string(dAtA[iNdEx:postIndex])
|
|
iNdEx = postIndex
|
|
case 4:
|
|
if wireType != 2 {
|
|
return fmt.Errorf("proto: wrong wireType = %d for field Phones", wireType)
|
|
}
|
|
var msglen int
|
|
for shift := uint(0); ; shift += 7 {
|
|
if shift >= 64 {
|
|
return ErrIntOverflowTest
|
|
}
|
|
if iNdEx >= l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
b := dAtA[iNdEx]
|
|
iNdEx++
|
|
msglen |= int(b&0x7F) << shift
|
|
if b < 0x80 {
|
|
break
|
|
}
|
|
}
|
|
if msglen < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
postIndex := iNdEx + msglen
|
|
if postIndex < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
if postIndex > l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
m.Phones = append(m.Phones, &Person_PhoneNumber{})
|
|
if err := m.Phones[len(m.Phones)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
|
|
return err
|
|
}
|
|
iNdEx = postIndex
|
|
case 5:
|
|
if wireType != 2 {
|
|
return fmt.Errorf("proto: wrong wireType = %d for field LastUpdated", wireType)
|
|
}
|
|
var msglen int
|
|
for shift := uint(0); ; shift += 7 {
|
|
if shift >= 64 {
|
|
return ErrIntOverflowTest
|
|
}
|
|
if iNdEx >= l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
b := dAtA[iNdEx]
|
|
iNdEx++
|
|
msglen |= int(b&0x7F) << shift
|
|
if b < 0x80 {
|
|
break
|
|
}
|
|
}
|
|
if msglen < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
postIndex := iNdEx + msglen
|
|
if postIndex < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
if postIndex > l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
if m.LastUpdated == nil {
|
|
m.LastUpdated = &types.Timestamp{}
|
|
}
|
|
if err := m.LastUpdated.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
|
|
return err
|
|
}
|
|
iNdEx = postIndex
|
|
default:
|
|
iNdEx = preIndex
|
|
skippy, err := skipTest(dAtA[iNdEx:])
|
|
if err != nil {
|
|
return err
|
|
}
|
|
if skippy < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
if (iNdEx + skippy) < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
if (iNdEx + skippy) > l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
|
|
iNdEx += skippy
|
|
}
|
|
}
|
|
|
|
if iNdEx > l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
return nil
|
|
}
|
|
func (m *Person_PhoneNumber) Unmarshal(dAtA []byte) error {
|
|
l := len(dAtA)
|
|
iNdEx := 0
|
|
for iNdEx < l {
|
|
preIndex := iNdEx
|
|
var wire uint64
|
|
for shift := uint(0); ; shift += 7 {
|
|
if shift >= 64 {
|
|
return ErrIntOverflowTest
|
|
}
|
|
if iNdEx >= l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
b := dAtA[iNdEx]
|
|
iNdEx++
|
|
wire |= uint64(b&0x7F) << shift
|
|
if b < 0x80 {
|
|
break
|
|
}
|
|
}
|
|
fieldNum := int32(wire >> 3)
|
|
wireType := int(wire & 0x7)
|
|
if wireType == 4 {
|
|
return fmt.Errorf("proto: PhoneNumber: wiretype end group for non-group")
|
|
}
|
|
if fieldNum <= 0 {
|
|
return fmt.Errorf("proto: PhoneNumber: illegal tag %d (wire type %d)", fieldNum, wire)
|
|
}
|
|
switch fieldNum {
|
|
case 1:
|
|
if wireType != 2 {
|
|
return fmt.Errorf("proto: wrong wireType = %d for field Number", wireType)
|
|
}
|
|
var stringLen uint64
|
|
for shift := uint(0); ; shift += 7 {
|
|
if shift >= 64 {
|
|
return ErrIntOverflowTest
|
|
}
|
|
if iNdEx >= l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
b := dAtA[iNdEx]
|
|
iNdEx++
|
|
stringLen |= uint64(b&0x7F) << shift
|
|
if b < 0x80 {
|
|
break
|
|
}
|
|
}
|
|
intStringLen := int(stringLen)
|
|
if intStringLen < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
postIndex := iNdEx + intStringLen
|
|
if postIndex < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
if postIndex > l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
m.Number = string(dAtA[iNdEx:postIndex])
|
|
iNdEx = postIndex
|
|
case 2:
|
|
if wireType != 0 {
|
|
return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType)
|
|
}
|
|
m.Type = 0
|
|
for shift := uint(0); ; shift += 7 {
|
|
if shift >= 64 {
|
|
return ErrIntOverflowTest
|
|
}
|
|
if iNdEx >= l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
b := dAtA[iNdEx]
|
|
iNdEx++
|
|
m.Type |= Person_PhoneType(b&0x7F) << shift
|
|
if b < 0x80 {
|
|
break
|
|
}
|
|
}
|
|
default:
|
|
iNdEx = preIndex
|
|
skippy, err := skipTest(dAtA[iNdEx:])
|
|
if err != nil {
|
|
return err
|
|
}
|
|
if skippy < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
if (iNdEx + skippy) < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
if (iNdEx + skippy) > l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
|
|
iNdEx += skippy
|
|
}
|
|
}
|
|
|
|
if iNdEx > l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
return nil
|
|
}
|
|
func (m *AddressBook) Unmarshal(dAtA []byte) error {
|
|
l := len(dAtA)
|
|
iNdEx := 0
|
|
for iNdEx < l {
|
|
preIndex := iNdEx
|
|
var wire uint64
|
|
for shift := uint(0); ; shift += 7 {
|
|
if shift >= 64 {
|
|
return ErrIntOverflowTest
|
|
}
|
|
if iNdEx >= l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
b := dAtA[iNdEx]
|
|
iNdEx++
|
|
wire |= uint64(b&0x7F) << shift
|
|
if b < 0x80 {
|
|
break
|
|
}
|
|
}
|
|
fieldNum := int32(wire >> 3)
|
|
wireType := int(wire & 0x7)
|
|
if wireType == 4 {
|
|
return fmt.Errorf("proto: AddressBook: wiretype end group for non-group")
|
|
}
|
|
if fieldNum <= 0 {
|
|
return fmt.Errorf("proto: AddressBook: illegal tag %d (wire type %d)", fieldNum, wire)
|
|
}
|
|
switch fieldNum {
|
|
case 1:
|
|
if wireType != 2 {
|
|
return fmt.Errorf("proto: wrong wireType = %d for field People", wireType)
|
|
}
|
|
var msglen int
|
|
for shift := uint(0); ; shift += 7 {
|
|
if shift >= 64 {
|
|
return ErrIntOverflowTest
|
|
}
|
|
if iNdEx >= l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
b := dAtA[iNdEx]
|
|
iNdEx++
|
|
msglen |= int(b&0x7F) << shift
|
|
if b < 0x80 {
|
|
break
|
|
}
|
|
}
|
|
if msglen < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
postIndex := iNdEx + msglen
|
|
if postIndex < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
if postIndex > l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
m.People = append(m.People, &Person{})
|
|
if err := m.People[len(m.People)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
|
|
return err
|
|
}
|
|
iNdEx = postIndex
|
|
default:
|
|
iNdEx = preIndex
|
|
skippy, err := skipTest(dAtA[iNdEx:])
|
|
if err != nil {
|
|
return err
|
|
}
|
|
if skippy < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
if (iNdEx + skippy) < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
if (iNdEx + skippy) > l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
|
|
iNdEx += skippy
|
|
}
|
|
}
|
|
|
|
if iNdEx > l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
return nil
|
|
}
|
|
func (m *TestSimpleMessage) Unmarshal(dAtA []byte) error {
|
|
l := len(dAtA)
|
|
iNdEx := 0
|
|
for iNdEx < l {
|
|
preIndex := iNdEx
|
|
var wire uint64
|
|
for shift := uint(0); ; shift += 7 {
|
|
if shift >= 64 {
|
|
return ErrIntOverflowTest
|
|
}
|
|
if iNdEx >= l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
b := dAtA[iNdEx]
|
|
iNdEx++
|
|
wire |= uint64(b&0x7F) << shift
|
|
if b < 0x80 {
|
|
break
|
|
}
|
|
}
|
|
fieldNum := int32(wire >> 3)
|
|
wireType := int(wire & 0x7)
|
|
if wireType == 4 {
|
|
return fmt.Errorf("proto: TestSimpleMessage: wiretype end group for non-group")
|
|
}
|
|
if fieldNum <= 0 {
|
|
return fmt.Errorf("proto: TestSimpleMessage: illegal tag %d (wire type %d)", fieldNum, wire)
|
|
}
|
|
switch fieldNum {
|
|
case 1:
|
|
if wireType != 2 {
|
|
return fmt.Errorf("proto: wrong wireType = %d for field Foo", wireType)
|
|
}
|
|
var byteLen int
|
|
for shift := uint(0); ; shift += 7 {
|
|
if shift >= 64 {
|
|
return ErrIntOverflowTest
|
|
}
|
|
if iNdEx >= l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
b := dAtA[iNdEx]
|
|
iNdEx++
|
|
byteLen |= int(b&0x7F) << shift
|
|
if b < 0x80 {
|
|
break
|
|
}
|
|
}
|
|
if byteLen < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
postIndex := iNdEx + byteLen
|
|
if postIndex < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
if postIndex > l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
m.Foo = append(m.Foo[:0], dAtA[iNdEx:postIndex]...)
|
|
if m.Foo == nil {
|
|
m.Foo = []byte{}
|
|
}
|
|
iNdEx = postIndex
|
|
case 2:
|
|
if wireType != 0 {
|
|
return fmt.Errorf("proto: wrong wireType = %d for field Bar", wireType)
|
|
}
|
|
m.Bar = 0
|
|
for shift := uint(0); ; shift += 7 {
|
|
if shift >= 64 {
|
|
return ErrIntOverflowTest
|
|
}
|
|
if iNdEx >= l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
b := dAtA[iNdEx]
|
|
iNdEx++
|
|
m.Bar |= uint64(b&0x7F) << shift
|
|
if b < 0x80 {
|
|
break
|
|
}
|
|
}
|
|
default:
|
|
iNdEx = preIndex
|
|
skippy, err := skipTest(dAtA[iNdEx:])
|
|
if err != nil {
|
|
return err
|
|
}
|
|
if skippy < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
if (iNdEx + skippy) < 0 {
|
|
return ErrInvalidLengthTest
|
|
}
|
|
if (iNdEx + skippy) > l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
|
|
iNdEx += skippy
|
|
}
|
|
}
|
|
|
|
if iNdEx > l {
|
|
return io.ErrUnexpectedEOF
|
|
}
|
|
return nil
|
|
}
|
|
func skipTest(dAtA []byte) (n int, err error) {
|
|
l := len(dAtA)
|
|
iNdEx := 0
|
|
depth := 0
|
|
for iNdEx < l {
|
|
var wire uint64
|
|
for shift := uint(0); ; shift += 7 {
|
|
if shift >= 64 {
|
|
return 0, ErrIntOverflowTest
|
|
}
|
|
if iNdEx >= l {
|
|
return 0, io.ErrUnexpectedEOF
|
|
}
|
|
b := dAtA[iNdEx]
|
|
iNdEx++
|
|
wire |= (uint64(b) & 0x7F) << shift
|
|
if b < 0x80 {
|
|
break
|
|
}
|
|
}
|
|
wireType := int(wire & 0x7)
|
|
switch wireType {
|
|
case 0:
|
|
for shift := uint(0); ; shift += 7 {
|
|
if shift >= 64 {
|
|
return 0, ErrIntOverflowTest
|
|
}
|
|
if iNdEx >= l {
|
|
return 0, io.ErrUnexpectedEOF
|
|
}
|
|
iNdEx++
|
|
if dAtA[iNdEx-1] < 0x80 {
|
|
break
|
|
}
|
|
}
|
|
case 1:
|
|
iNdEx += 8
|
|
case 2:
|
|
var length int
|
|
for shift := uint(0); ; shift += 7 {
|
|
if shift >= 64 {
|
|
return 0, ErrIntOverflowTest
|
|
}
|
|
if iNdEx >= l {
|
|
return 0, io.ErrUnexpectedEOF
|
|
}
|
|
b := dAtA[iNdEx]
|
|
iNdEx++
|
|
length |= (int(b) & 0x7F) << shift
|
|
if b < 0x80 {
|
|
break
|
|
}
|
|
}
|
|
if length < 0 {
|
|
return 0, ErrInvalidLengthTest
|
|
}
|
|
iNdEx += length
|
|
case 3:
|
|
depth++
|
|
case 4:
|
|
if depth == 0 {
|
|
return 0, ErrUnexpectedEndOfGroupTest
|
|
}
|
|
depth--
|
|
case 5:
|
|
iNdEx += 4
|
|
default:
|
|
return 0, fmt.Errorf("proto: illegal wireType %d", wireType)
|
|
}
|
|
if iNdEx < 0 {
|
|
return 0, ErrInvalidLengthTest
|
|
}
|
|
if depth == 0 {
|
|
return iNdEx, nil
|
|
}
|
|
}
|
|
return 0, io.ErrUnexpectedEOF
|
|
}
|
|
|
|
var (
|
|
ErrInvalidLengthTest = fmt.Errorf("proto: negative length found during unmarshaling")
|
|
ErrIntOverflowTest = fmt.Errorf("proto: integer overflow")
|
|
ErrUnexpectedEndOfGroupTest = fmt.Errorf("proto: unexpected end of group")
|
|
)
|