From 34a3f0cef0b1e2f94c9c81a4fce7feb00fec2973 Mon Sep 17 00:00:00 2001 From: 0x19 Date: Tue, 17 Oct 2023 15:49:37 +0200 Subject: [PATCH] Unary Kind --- ast/unary_prefix.proto | 1 + ast/unary_suffix.proto | 1 + dist/docs/docs.json | 24 ++++++++ dist/go/ast/unary_prefix.pb.go | 94 +++++++++++++++++-------------- dist/go/ast/unary_suffix.pb.go | 94 +++++++++++++++++-------------- dist/js/ast/unary_prefix_pb.d.ts | 4 ++ dist/js/ast/unary_prefix_pb.js | 30 ++++++++++ dist/js/ast/unary_suffix_pb.d.ts | 4 ++ dist/js/ast/unary_suffix_pb.js | 30 ++++++++++ dist/protosets/unpack.protoset | Bin 300660 -> 300860 bytes 10 files changed, 200 insertions(+), 82 deletions(-) diff --git a/ast/unary_prefix.proto b/ast/unary_prefix.proto index 9745536..d342067 100644 --- a/ast/unary_prefix.proto +++ b/ast/unary_prefix.proto @@ -10,6 +10,7 @@ import "xds/type/v3/typed_struct.proto"; message UnaryPrefix { int64 id = 1; unpack.v1.ast.NodeType node_type = 2; + unpack.v1.ast.NodeType kind = 13; unpack.v1.ast.Src src = 3; unpack.v1.ast.Operator operator = 4; bool prefix = 5; diff --git a/ast/unary_suffix.proto b/ast/unary_suffix.proto index e085458..434d6df 100644 --- a/ast/unary_suffix.proto +++ b/ast/unary_suffix.proto @@ -10,6 +10,7 @@ import "xds/type/v3/typed_struct.proto"; message UnarySuffix { int64 id = 1; unpack.v1.ast.NodeType node_type = 2; + unpack.v1.ast.NodeType kind = 13; unpack.v1.ast.Src src = 3; unpack.v1.ast.Operator operator = 4; bool prefix = 5; diff --git a/dist/docs/docs.json b/dist/docs/docs.json index a21b6f6..1bad15a 100644 --- a/dist/docs/docs.json +++ b/dist/docs/docs.json @@ -12799,6 +12799,18 @@ "oneofdecl": "", "defaultValue": "" }, + { + "name": "kind", + "description": "", + "label": "", + "type": "NodeType", + "longType": "NodeType", + "fullType": "unpack.v1.ast.NodeType", + "ismap": false, + "isoneof": false, + "oneofdecl": "", + "defaultValue": "" + }, { "name": "src", "description": "", @@ -12969,6 +12981,18 @@ "oneofdecl": "", "defaultValue": "" }, + { + "name": "kind", + "description": "", + "label": "", + "type": "NodeType", + "longType": "NodeType", + "fullType": "unpack.v1.ast.NodeType", + "ismap": false, + "isoneof": false, + "oneofdecl": "", + "defaultValue": "" + }, { "name": "src", "description": "", diff --git a/dist/go/ast/unary_prefix.pb.go b/dist/go/ast/unary_prefix.pb.go index ae262fa..e3d4863 100644 --- a/dist/go/ast/unary_prefix.pb.go +++ b/dist/go/ast/unary_prefix.pb.go @@ -28,6 +28,7 @@ type UnaryPrefix struct { Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` NodeType NodeType `protobuf:"varint,2,opt,name=node_type,json=nodeType,proto3,enum=unpack.v1.ast.NodeType" json:"node_type,omitempty"` + Kind NodeType `protobuf:"varint,13,opt,name=kind,proto3,enum=unpack.v1.ast.NodeType" json:"kind,omitempty"` Src *Src `protobuf:"bytes,3,opt,name=src,proto3" json:"src,omitempty"` Operator Operator `protobuf:"varint,4,opt,name=operator,proto3,enum=unpack.v1.ast.Operator" json:"operator,omitempty"` Prefix bool `protobuf:"varint,5,opt,name=prefix,proto3" json:"prefix,omitempty"` @@ -86,6 +87,13 @@ func (x *UnaryPrefix) GetNodeType() NodeType { return NodeType_NT_DEFAULT } +func (x *UnaryPrefix) GetKind() NodeType { + if x != nil { + return x.Kind + } + return NodeType_NT_DEFAULT +} + func (x *UnaryPrefix) GetSrc() *Src { if x != nil { return x.Src @@ -166,43 +174,46 @@ var file_ast_unary_prefix_proto_rawDesc = []byte{ 0x63, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x13, 0x61, 0x73, 0x74, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1e, 0x78, 0x64, 0x73, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x2f, 0x76, 0x33, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x64, 0x5f, - 0x73, 0x74, 0x72, 0x75, 0x63, 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x86, 0x04, 0x0a, + 0x73, 0x74, 0x72, 0x75, 0x63, 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xb3, 0x04, 0x0a, 0x0b, 0x55, 0x6e, 0x61, 0x72, 0x79, 0x50, 0x72, 0x65, 0x66, 0x69, 0x78, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x12, 0x34, 0x0a, 0x09, 0x6e, 0x6f, 0x64, 0x65, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x17, 0x2e, 0x75, 0x6e, 0x70, 0x61, 0x63, 0x6b, 0x2e, 0x76, 0x31, 0x2e, 0x61, 0x73, 0x74, 0x2e, 0x4e, 0x6f, 0x64, 0x65, 0x54, 0x79, 0x70, 0x65, 0x52, 0x08, 0x6e, 0x6f, 0x64, 0x65, 0x54, 0x79, - 0x70, 0x65, 0x12, 0x24, 0x0a, 0x03, 0x73, 0x72, 0x63, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, - 0x12, 0x2e, 0x75, 0x6e, 0x70, 0x61, 0x63, 0x6b, 0x2e, 0x76, 0x31, 0x2e, 0x61, 0x73, 0x74, 0x2e, - 0x53, 0x72, 0x63, 0x52, 0x03, 0x73, 0x72, 0x63, 0x12, 0x33, 0x0a, 0x08, 0x6f, 0x70, 0x65, 0x72, - 0x61, 0x74, 0x6f, 0x72, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x17, 0x2e, 0x75, 0x6e, 0x70, - 0x61, 0x63, 0x6b, 0x2e, 0x76, 0x31, 0x2e, 0x61, 0x73, 0x74, 0x2e, 0x4f, 0x70, 0x65, 0x72, 0x61, - 0x74, 0x6f, 0x72, 0x52, 0x08, 0x6f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x16, 0x0a, - 0x06, 0x70, 0x72, 0x65, 0x66, 0x69, 0x78, 0x18, 0x05, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x70, - 0x72, 0x65, 0x66, 0x69, 0x78, 0x12, 0x1f, 0x0a, 0x0b, 0x69, 0x73, 0x5f, 0x63, 0x6f, 0x6e, 0x73, - 0x74, 0x61, 0x6e, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0a, 0x69, 0x73, 0x43, 0x6f, - 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x74, 0x12, 0x1c, 0x0a, 0x0a, 0x69, 0x73, 0x5f, 0x6c, 0x5f, 0x76, - 0x61, 0x6c, 0x75, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x08, 0x52, 0x08, 0x69, 0x73, 0x4c, 0x56, - 0x61, 0x6c, 0x75, 0x65, 0x12, 0x17, 0x0a, 0x07, 0x69, 0x73, 0x5f, 0x70, 0x75, 0x72, 0x65, 0x18, - 0x08, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x69, 0x73, 0x50, 0x75, 0x72, 0x65, 0x12, 0x2a, 0x0a, - 0x11, 0x6c, 0x5f, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x5f, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, - 0x65, 0x64, 0x18, 0x09, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0f, 0x6c, 0x56, 0x61, 0x6c, 0x75, 0x65, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x65, 0x64, 0x12, 0x38, 0x0a, 0x0a, 0x65, 0x78, 0x70, - 0x72, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x18, 0x2e, - 0x78, 0x64, 0x73, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x76, 0x33, 0x2e, 0x54, 0x79, 0x70, 0x65, - 0x64, 0x53, 0x74, 0x72, 0x75, 0x63, 0x74, 0x52, 0x0a, 0x65, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, - 0x69, 0x6f, 0x6e, 0x12, 0x35, 0x0a, 0x16, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, - 0x64, 0x5f, 0x64, 0x65, 0x63, 0x6c, 0x61, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x0b, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x15, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x64, 0x44, - 0x65, 0x63, 0x6c, 0x61, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x49, 0x0a, 0x10, 0x74, 0x79, - 0x70, 0x65, 0x5f, 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x0c, - 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x75, 0x6e, 0x70, 0x61, 0x63, 0x6b, 0x2e, 0x76, 0x31, - 0x2e, 0x61, 0x73, 0x74, 0x2e, 0x54, 0x79, 0x70, 0x65, 0x44, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, - 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0f, 0x74, 0x79, 0x70, 0x65, 0x44, 0x65, 0x73, 0x63, 0x72, 0x69, - 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x42, 0x30, 0x5a, 0x2e, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, - 0x63, 0x6f, 0x6d, 0x2f, 0x75, 0x6e, 0x70, 0x61, 0x63, 0x6b, 0x64, 0x65, 0x76, 0x2f, 0x70, 0x72, - 0x6f, 0x74, 0x6f, 0x73, 0x2f, 0x64, 0x69, 0x73, 0x74, 0x2f, 0x67, 0x6f, 0x2f, 0x61, 0x73, 0x74, - 0x3b, 0x61, 0x73, 0x74, 0x5f, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x70, 0x65, 0x12, 0x2b, 0x0a, 0x04, 0x6b, 0x69, 0x6e, 0x64, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x0e, + 0x32, 0x17, 0x2e, 0x75, 0x6e, 0x70, 0x61, 0x63, 0x6b, 0x2e, 0x76, 0x31, 0x2e, 0x61, 0x73, 0x74, + 0x2e, 0x4e, 0x6f, 0x64, 0x65, 0x54, 0x79, 0x70, 0x65, 0x52, 0x04, 0x6b, 0x69, 0x6e, 0x64, 0x12, + 0x24, 0x0a, 0x03, 0x73, 0x72, 0x63, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x75, + 0x6e, 0x70, 0x61, 0x63, 0x6b, 0x2e, 0x76, 0x31, 0x2e, 0x61, 0x73, 0x74, 0x2e, 0x53, 0x72, 0x63, + 0x52, 0x03, 0x73, 0x72, 0x63, 0x12, 0x33, 0x0a, 0x08, 0x6f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x6f, + 0x72, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x17, 0x2e, 0x75, 0x6e, 0x70, 0x61, 0x63, 0x6b, + 0x2e, 0x76, 0x31, 0x2e, 0x61, 0x73, 0x74, 0x2e, 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, + 0x52, 0x08, 0x6f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x16, 0x0a, 0x06, 0x70, 0x72, + 0x65, 0x66, 0x69, 0x78, 0x18, 0x05, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x70, 0x72, 0x65, 0x66, + 0x69, 0x78, 0x12, 0x1f, 0x0a, 0x0b, 0x69, 0x73, 0x5f, 0x63, 0x6f, 0x6e, 0x73, 0x74, 0x61, 0x6e, + 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0a, 0x69, 0x73, 0x43, 0x6f, 0x6e, 0x73, 0x74, + 0x61, 0x6e, 0x74, 0x12, 0x1c, 0x0a, 0x0a, 0x69, 0x73, 0x5f, 0x6c, 0x5f, 0x76, 0x61, 0x6c, 0x75, + 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x08, 0x52, 0x08, 0x69, 0x73, 0x4c, 0x56, 0x61, 0x6c, 0x75, + 0x65, 0x12, 0x17, 0x0a, 0x07, 0x69, 0x73, 0x5f, 0x70, 0x75, 0x72, 0x65, 0x18, 0x08, 0x20, 0x01, + 0x28, 0x08, 0x52, 0x06, 0x69, 0x73, 0x50, 0x75, 0x72, 0x65, 0x12, 0x2a, 0x0a, 0x11, 0x6c, 0x5f, + 0x76, 0x61, 0x6c, 0x75, 0x65, 0x5f, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x65, 0x64, 0x18, + 0x09, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0f, 0x6c, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x65, 0x64, 0x12, 0x38, 0x0a, 0x0a, 0x65, 0x78, 0x70, 0x72, 0x65, 0x73, + 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x78, 0x64, 0x73, + 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x76, 0x33, 0x2e, 0x54, 0x79, 0x70, 0x65, 0x64, 0x53, 0x74, + 0x72, 0x75, 0x63, 0x74, 0x52, 0x0a, 0x65, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, + 0x12, 0x35, 0x0a, 0x16, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x64, 0x5f, 0x64, + 0x65, 0x63, 0x6c, 0x61, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x15, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x64, 0x44, 0x65, 0x63, 0x6c, + 0x61, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x49, 0x0a, 0x10, 0x74, 0x79, 0x70, 0x65, 0x5f, + 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x0c, 0x20, 0x01, 0x28, + 0x0b, 0x32, 0x1e, 0x2e, 0x75, 0x6e, 0x70, 0x61, 0x63, 0x6b, 0x2e, 0x76, 0x31, 0x2e, 0x61, 0x73, + 0x74, 0x2e, 0x54, 0x79, 0x70, 0x65, 0x44, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, + 0x6e, 0x52, 0x0f, 0x74, 0x79, 0x70, 0x65, 0x44, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, + 0x6f, 0x6e, 0x42, 0x30, 0x5a, 0x2e, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, + 0x2f, 0x75, 0x6e, 0x70, 0x61, 0x63, 0x6b, 0x64, 0x65, 0x76, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x73, 0x2f, 0x64, 0x69, 0x73, 0x74, 0x2f, 0x67, 0x6f, 0x2f, 0x61, 0x73, 0x74, 0x3b, 0x61, 0x73, + 0x74, 0x5f, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -228,15 +239,16 @@ var file_ast_unary_prefix_proto_goTypes = []interface{}{ } var file_ast_unary_prefix_proto_depIdxs = []int32{ 1, // 0: unpack.v1.ast.UnaryPrefix.node_type:type_name -> unpack.v1.ast.NodeType - 2, // 1: unpack.v1.ast.UnaryPrefix.src:type_name -> unpack.v1.ast.Src - 3, // 2: unpack.v1.ast.UnaryPrefix.operator:type_name -> unpack.v1.ast.Operator - 4, // 3: unpack.v1.ast.UnaryPrefix.expression:type_name -> xds.type.v3.TypedStruct - 5, // 4: unpack.v1.ast.UnaryPrefix.type_description:type_name -> unpack.v1.ast.TypeDescription - 5, // [5:5] is the sub-list for method output_type - 5, // [5:5] is the sub-list for method input_type - 5, // [5:5] is the sub-list for extension type_name - 5, // [5:5] is the sub-list for extension extendee - 0, // [0:5] is the sub-list for field type_name + 1, // 1: unpack.v1.ast.UnaryPrefix.kind:type_name -> unpack.v1.ast.NodeType + 2, // 2: unpack.v1.ast.UnaryPrefix.src:type_name -> unpack.v1.ast.Src + 3, // 3: unpack.v1.ast.UnaryPrefix.operator:type_name -> unpack.v1.ast.Operator + 4, // 4: unpack.v1.ast.UnaryPrefix.expression:type_name -> xds.type.v3.TypedStruct + 5, // 5: unpack.v1.ast.UnaryPrefix.type_description:type_name -> unpack.v1.ast.TypeDescription + 6, // [6:6] is the sub-list for method output_type + 6, // [6:6] is the sub-list for method input_type + 6, // [6:6] is the sub-list for extension type_name + 6, // [6:6] is the sub-list for extension extendee + 0, // [0:6] is the sub-list for field type_name } func init() { file_ast_unary_prefix_proto_init() } diff --git a/dist/go/ast/unary_suffix.pb.go b/dist/go/ast/unary_suffix.pb.go index a797e84..0743004 100644 --- a/dist/go/ast/unary_suffix.pb.go +++ b/dist/go/ast/unary_suffix.pb.go @@ -28,6 +28,7 @@ type UnarySuffix struct { Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` NodeType NodeType `protobuf:"varint,2,opt,name=node_type,json=nodeType,proto3,enum=unpack.v1.ast.NodeType" json:"node_type,omitempty"` + Kind NodeType `protobuf:"varint,13,opt,name=kind,proto3,enum=unpack.v1.ast.NodeType" json:"kind,omitempty"` Src *Src `protobuf:"bytes,3,opt,name=src,proto3" json:"src,omitempty"` Operator Operator `protobuf:"varint,4,opt,name=operator,proto3,enum=unpack.v1.ast.Operator" json:"operator,omitempty"` Prefix bool `protobuf:"varint,5,opt,name=prefix,proto3" json:"prefix,omitempty"` @@ -86,6 +87,13 @@ func (x *UnarySuffix) GetNodeType() NodeType { return NodeType_NT_DEFAULT } +func (x *UnarySuffix) GetKind() NodeType { + if x != nil { + return x.Kind + } + return NodeType_NT_DEFAULT +} + func (x *UnarySuffix) GetSrc() *Src { if x != nil { return x.Src @@ -166,43 +174,46 @@ var file_ast_unary_suffix_proto_rawDesc = []byte{ 0x63, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x13, 0x61, 0x73, 0x74, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1e, 0x78, 0x64, 0x73, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x2f, 0x76, 0x33, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x64, 0x5f, - 0x73, 0x74, 0x72, 0x75, 0x63, 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x86, 0x04, 0x0a, + 0x73, 0x74, 0x72, 0x75, 0x63, 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xb3, 0x04, 0x0a, 0x0b, 0x55, 0x6e, 0x61, 0x72, 0x79, 0x53, 0x75, 0x66, 0x66, 0x69, 0x78, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x12, 0x34, 0x0a, 0x09, 0x6e, 0x6f, 0x64, 0x65, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x17, 0x2e, 0x75, 0x6e, 0x70, 0x61, 0x63, 0x6b, 0x2e, 0x76, 0x31, 0x2e, 0x61, 0x73, 0x74, 0x2e, 0x4e, 0x6f, 0x64, 0x65, 0x54, 0x79, 0x70, 0x65, 0x52, 0x08, 0x6e, 0x6f, 0x64, 0x65, 0x54, 0x79, - 0x70, 0x65, 0x12, 0x24, 0x0a, 0x03, 0x73, 0x72, 0x63, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, - 0x12, 0x2e, 0x75, 0x6e, 0x70, 0x61, 0x63, 0x6b, 0x2e, 0x76, 0x31, 0x2e, 0x61, 0x73, 0x74, 0x2e, - 0x53, 0x72, 0x63, 0x52, 0x03, 0x73, 0x72, 0x63, 0x12, 0x33, 0x0a, 0x08, 0x6f, 0x70, 0x65, 0x72, - 0x61, 0x74, 0x6f, 0x72, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x17, 0x2e, 0x75, 0x6e, 0x70, - 0x61, 0x63, 0x6b, 0x2e, 0x76, 0x31, 0x2e, 0x61, 0x73, 0x74, 0x2e, 0x4f, 0x70, 0x65, 0x72, 0x61, - 0x74, 0x6f, 0x72, 0x52, 0x08, 0x6f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x16, 0x0a, - 0x06, 0x70, 0x72, 0x65, 0x66, 0x69, 0x78, 0x18, 0x05, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x70, - 0x72, 0x65, 0x66, 0x69, 0x78, 0x12, 0x1f, 0x0a, 0x0b, 0x69, 0x73, 0x5f, 0x63, 0x6f, 0x6e, 0x73, - 0x74, 0x61, 0x6e, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0a, 0x69, 0x73, 0x43, 0x6f, - 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x74, 0x12, 0x1c, 0x0a, 0x0a, 0x69, 0x73, 0x5f, 0x6c, 0x5f, 0x76, - 0x61, 0x6c, 0x75, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x08, 0x52, 0x08, 0x69, 0x73, 0x4c, 0x56, - 0x61, 0x6c, 0x75, 0x65, 0x12, 0x17, 0x0a, 0x07, 0x69, 0x73, 0x5f, 0x70, 0x75, 0x72, 0x65, 0x18, - 0x08, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x69, 0x73, 0x50, 0x75, 0x72, 0x65, 0x12, 0x2a, 0x0a, - 0x11, 0x6c, 0x5f, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x5f, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, - 0x65, 0x64, 0x18, 0x09, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0f, 0x6c, 0x56, 0x61, 0x6c, 0x75, 0x65, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x65, 0x64, 0x12, 0x38, 0x0a, 0x0a, 0x65, 0x78, 0x70, - 0x72, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x18, 0x2e, - 0x78, 0x64, 0x73, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x76, 0x33, 0x2e, 0x54, 0x79, 0x70, 0x65, - 0x64, 0x53, 0x74, 0x72, 0x75, 0x63, 0x74, 0x52, 0x0a, 0x65, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, - 0x69, 0x6f, 0x6e, 0x12, 0x35, 0x0a, 0x16, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, - 0x64, 0x5f, 0x64, 0x65, 0x63, 0x6c, 0x61, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x0b, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x15, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x64, 0x44, - 0x65, 0x63, 0x6c, 0x61, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x49, 0x0a, 0x10, 0x74, 0x79, - 0x70, 0x65, 0x5f, 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x0c, - 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x75, 0x6e, 0x70, 0x61, 0x63, 0x6b, 0x2e, 0x76, 0x31, - 0x2e, 0x61, 0x73, 0x74, 0x2e, 0x54, 0x79, 0x70, 0x65, 0x44, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, - 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0f, 0x74, 0x79, 0x70, 0x65, 0x44, 0x65, 0x73, 0x63, 0x72, 0x69, - 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x42, 0x30, 0x5a, 0x2e, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, - 0x63, 0x6f, 0x6d, 0x2f, 0x75, 0x6e, 0x70, 0x61, 0x63, 0x6b, 0x64, 0x65, 0x76, 0x2f, 0x70, 0x72, - 0x6f, 0x74, 0x6f, 0x73, 0x2f, 0x64, 0x69, 0x73, 0x74, 0x2f, 0x67, 0x6f, 0x2f, 0x61, 0x73, 0x74, - 0x3b, 0x61, 0x73, 0x74, 0x5f, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x70, 0x65, 0x12, 0x2b, 0x0a, 0x04, 0x6b, 0x69, 0x6e, 0x64, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x0e, + 0x32, 0x17, 0x2e, 0x75, 0x6e, 0x70, 0x61, 0x63, 0x6b, 0x2e, 0x76, 0x31, 0x2e, 0x61, 0x73, 0x74, + 0x2e, 0x4e, 0x6f, 0x64, 0x65, 0x54, 0x79, 0x70, 0x65, 0x52, 0x04, 0x6b, 0x69, 0x6e, 0x64, 0x12, + 0x24, 0x0a, 0x03, 0x73, 0x72, 0x63, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x75, + 0x6e, 0x70, 0x61, 0x63, 0x6b, 0x2e, 0x76, 0x31, 0x2e, 0x61, 0x73, 0x74, 0x2e, 0x53, 0x72, 0x63, + 0x52, 0x03, 0x73, 0x72, 0x63, 0x12, 0x33, 0x0a, 0x08, 0x6f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x6f, + 0x72, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x17, 0x2e, 0x75, 0x6e, 0x70, 0x61, 0x63, 0x6b, + 0x2e, 0x76, 0x31, 0x2e, 0x61, 0x73, 0x74, 0x2e, 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, + 0x52, 0x08, 0x6f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x16, 0x0a, 0x06, 0x70, 0x72, + 0x65, 0x66, 0x69, 0x78, 0x18, 0x05, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x70, 0x72, 0x65, 0x66, + 0x69, 0x78, 0x12, 0x1f, 0x0a, 0x0b, 0x69, 0x73, 0x5f, 0x63, 0x6f, 0x6e, 0x73, 0x74, 0x61, 0x6e, + 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0a, 0x69, 0x73, 0x43, 0x6f, 0x6e, 0x73, 0x74, + 0x61, 0x6e, 0x74, 0x12, 0x1c, 0x0a, 0x0a, 0x69, 0x73, 0x5f, 0x6c, 0x5f, 0x76, 0x61, 0x6c, 0x75, + 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x08, 0x52, 0x08, 0x69, 0x73, 0x4c, 0x56, 0x61, 0x6c, 0x75, + 0x65, 0x12, 0x17, 0x0a, 0x07, 0x69, 0x73, 0x5f, 0x70, 0x75, 0x72, 0x65, 0x18, 0x08, 0x20, 0x01, + 0x28, 0x08, 0x52, 0x06, 0x69, 0x73, 0x50, 0x75, 0x72, 0x65, 0x12, 0x2a, 0x0a, 0x11, 0x6c, 0x5f, + 0x76, 0x61, 0x6c, 0x75, 0x65, 0x5f, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x65, 0x64, 0x18, + 0x09, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0f, 0x6c, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x65, 0x64, 0x12, 0x38, 0x0a, 0x0a, 0x65, 0x78, 0x70, 0x72, 0x65, 0x73, + 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x78, 0x64, 0x73, + 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x76, 0x33, 0x2e, 0x54, 0x79, 0x70, 0x65, 0x64, 0x53, 0x74, + 0x72, 0x75, 0x63, 0x74, 0x52, 0x0a, 0x65, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, + 0x12, 0x35, 0x0a, 0x16, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x64, 0x5f, 0x64, + 0x65, 0x63, 0x6c, 0x61, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x15, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x64, 0x44, 0x65, 0x63, 0x6c, + 0x61, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x49, 0x0a, 0x10, 0x74, 0x79, 0x70, 0x65, 0x5f, + 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x0c, 0x20, 0x01, 0x28, + 0x0b, 0x32, 0x1e, 0x2e, 0x75, 0x6e, 0x70, 0x61, 0x63, 0x6b, 0x2e, 0x76, 0x31, 0x2e, 0x61, 0x73, + 0x74, 0x2e, 0x54, 0x79, 0x70, 0x65, 0x44, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, + 0x6e, 0x52, 0x0f, 0x74, 0x79, 0x70, 0x65, 0x44, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, + 0x6f, 0x6e, 0x42, 0x30, 0x5a, 0x2e, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, + 0x2f, 0x75, 0x6e, 0x70, 0x61, 0x63, 0x6b, 0x64, 0x65, 0x76, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x73, 0x2f, 0x64, 0x69, 0x73, 0x74, 0x2f, 0x67, 0x6f, 0x2f, 0x61, 0x73, 0x74, 0x3b, 0x61, 0x73, + 0x74, 0x5f, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -228,15 +239,16 @@ var file_ast_unary_suffix_proto_goTypes = []interface{}{ } var file_ast_unary_suffix_proto_depIdxs = []int32{ 1, // 0: unpack.v1.ast.UnarySuffix.node_type:type_name -> unpack.v1.ast.NodeType - 2, // 1: unpack.v1.ast.UnarySuffix.src:type_name -> unpack.v1.ast.Src - 3, // 2: unpack.v1.ast.UnarySuffix.operator:type_name -> unpack.v1.ast.Operator - 4, // 3: unpack.v1.ast.UnarySuffix.expression:type_name -> xds.type.v3.TypedStruct - 5, // 4: unpack.v1.ast.UnarySuffix.type_description:type_name -> unpack.v1.ast.TypeDescription - 5, // [5:5] is the sub-list for method output_type - 5, // [5:5] is the sub-list for method input_type - 5, // [5:5] is the sub-list for extension type_name - 5, // [5:5] is the sub-list for extension extendee - 0, // [0:5] is the sub-list for field type_name + 1, // 1: unpack.v1.ast.UnarySuffix.kind:type_name -> unpack.v1.ast.NodeType + 2, // 2: unpack.v1.ast.UnarySuffix.src:type_name -> unpack.v1.ast.Src + 3, // 3: unpack.v1.ast.UnarySuffix.operator:type_name -> unpack.v1.ast.Operator + 4, // 4: unpack.v1.ast.UnarySuffix.expression:type_name -> xds.type.v3.TypedStruct + 5, // 5: unpack.v1.ast.UnarySuffix.type_description:type_name -> unpack.v1.ast.TypeDescription + 6, // [6:6] is the sub-list for method output_type + 6, // [6:6] is the sub-list for method input_type + 6, // [6:6] is the sub-list for extension type_name + 6, // [6:6] is the sub-list for extension extendee + 0, // [0:6] is the sub-list for field type_name } func init() { file_ast_unary_suffix_proto_init() } diff --git a/dist/js/ast/unary_prefix_pb.d.ts b/dist/js/ast/unary_prefix_pb.d.ts index f595dba..46705a0 100644 --- a/dist/js/ast/unary_prefix_pb.d.ts +++ b/dist/js/ast/unary_prefix_pb.d.ts @@ -13,6 +13,9 @@ export class UnaryPrefix extends jspb.Message { getNodeType(): ast_types_pb.NodeType; setNodeType(value: ast_types_pb.NodeType): UnaryPrefix; + getKind(): ast_types_pb.NodeType; + setKind(value: ast_types_pb.NodeType): UnaryPrefix; + getSrc(): ast_src_pb.Src | undefined; setSrc(value?: ast_src_pb.Src): UnaryPrefix; hasSrc(): boolean; @@ -61,6 +64,7 @@ export namespace UnaryPrefix { export type AsObject = { id: number, nodeType: ast_types_pb.NodeType, + kind: ast_types_pb.NodeType, src?: ast_src_pb.Src.AsObject, operator: ast_types_pb.Operator, prefix: boolean, diff --git a/dist/js/ast/unary_prefix_pb.js b/dist/js/ast/unary_prefix_pb.js index 87ded24..b242377 100644 --- a/dist/js/ast/unary_prefix_pb.js +++ b/dist/js/ast/unary_prefix_pb.js @@ -76,6 +76,7 @@ proto.unpack.v1.ast.UnaryPrefix.toObject = function(includeInstance, msg) { var f, obj = { id: jspb.Message.getFieldWithDefault(msg, 1, 0), nodeType: jspb.Message.getFieldWithDefault(msg, 2, 0), + kind: jspb.Message.getFieldWithDefault(msg, 13, 0), src: (f = msg.getSrc()) && ast_src_pb.Src.toObject(includeInstance, f), operator: jspb.Message.getFieldWithDefault(msg, 4, 0), prefix: jspb.Message.getBooleanFieldWithDefault(msg, 5, false), @@ -130,6 +131,10 @@ proto.unpack.v1.ast.UnaryPrefix.deserializeBinaryFromReader = function(msg, read var value = /** @type {!proto.unpack.v1.ast.NodeType} */ (reader.readEnum()); msg.setNodeType(value); break; + case 13: + var value = /** @type {!proto.unpack.v1.ast.NodeType} */ (reader.readEnum()); + msg.setKind(value); + break; case 3: var value = new ast_src_pb.Src; reader.readMessage(value,ast_src_pb.Src.deserializeBinaryFromReader); @@ -216,6 +221,13 @@ proto.unpack.v1.ast.UnaryPrefix.serializeBinaryToWriter = function(message, writ f ); } + f = message.getKind(); + if (f !== 0.0) { + writer.writeEnum( + 13, + f + ); + } f = message.getSrc(); if (f != null) { writer.writeMessage( @@ -328,6 +340,24 @@ proto.unpack.v1.ast.UnaryPrefix.prototype.setNodeType = function(value) { }; +/** + * optional NodeType kind = 13; + * @return {!proto.unpack.v1.ast.NodeType} + */ +proto.unpack.v1.ast.UnaryPrefix.prototype.getKind = function() { + return /** @type {!proto.unpack.v1.ast.NodeType} */ (jspb.Message.getFieldWithDefault(this, 13, 0)); +}; + + +/** + * @param {!proto.unpack.v1.ast.NodeType} value + * @return {!proto.unpack.v1.ast.UnaryPrefix} returns this + */ +proto.unpack.v1.ast.UnaryPrefix.prototype.setKind = function(value) { + return jspb.Message.setProto3EnumField(this, 13, value); +}; + + /** * optional Src src = 3; * @return {?proto.unpack.v1.ast.Src} diff --git a/dist/js/ast/unary_suffix_pb.d.ts b/dist/js/ast/unary_suffix_pb.d.ts index 965f407..43fd50d 100644 --- a/dist/js/ast/unary_suffix_pb.d.ts +++ b/dist/js/ast/unary_suffix_pb.d.ts @@ -13,6 +13,9 @@ export class UnarySuffix extends jspb.Message { getNodeType(): ast_types_pb.NodeType; setNodeType(value: ast_types_pb.NodeType): UnarySuffix; + getKind(): ast_types_pb.NodeType; + setKind(value: ast_types_pb.NodeType): UnarySuffix; + getSrc(): ast_src_pb.Src | undefined; setSrc(value?: ast_src_pb.Src): UnarySuffix; hasSrc(): boolean; @@ -61,6 +64,7 @@ export namespace UnarySuffix { export type AsObject = { id: number, nodeType: ast_types_pb.NodeType, + kind: ast_types_pb.NodeType, src?: ast_src_pb.Src.AsObject, operator: ast_types_pb.Operator, prefix: boolean, diff --git a/dist/js/ast/unary_suffix_pb.js b/dist/js/ast/unary_suffix_pb.js index b1c3bfd..164d890 100644 --- a/dist/js/ast/unary_suffix_pb.js +++ b/dist/js/ast/unary_suffix_pb.js @@ -76,6 +76,7 @@ proto.unpack.v1.ast.UnarySuffix.toObject = function(includeInstance, msg) { var f, obj = { id: jspb.Message.getFieldWithDefault(msg, 1, 0), nodeType: jspb.Message.getFieldWithDefault(msg, 2, 0), + kind: jspb.Message.getFieldWithDefault(msg, 13, 0), src: (f = msg.getSrc()) && ast_src_pb.Src.toObject(includeInstance, f), operator: jspb.Message.getFieldWithDefault(msg, 4, 0), prefix: jspb.Message.getBooleanFieldWithDefault(msg, 5, false), @@ -130,6 +131,10 @@ proto.unpack.v1.ast.UnarySuffix.deserializeBinaryFromReader = function(msg, read var value = /** @type {!proto.unpack.v1.ast.NodeType} */ (reader.readEnum()); msg.setNodeType(value); break; + case 13: + var value = /** @type {!proto.unpack.v1.ast.NodeType} */ (reader.readEnum()); + msg.setKind(value); + break; case 3: var value = new ast_src_pb.Src; reader.readMessage(value,ast_src_pb.Src.deserializeBinaryFromReader); @@ -216,6 +221,13 @@ proto.unpack.v1.ast.UnarySuffix.serializeBinaryToWriter = function(message, writ f ); } + f = message.getKind(); + if (f !== 0.0) { + writer.writeEnum( + 13, + f + ); + } f = message.getSrc(); if (f != null) { writer.writeMessage( @@ -328,6 +340,24 @@ proto.unpack.v1.ast.UnarySuffix.prototype.setNodeType = function(value) { }; +/** + * optional NodeType kind = 13; + * @return {!proto.unpack.v1.ast.NodeType} + */ +proto.unpack.v1.ast.UnarySuffix.prototype.getKind = function() { + return /** @type {!proto.unpack.v1.ast.NodeType} */ (jspb.Message.getFieldWithDefault(this, 13, 0)); +}; + + +/** + * @param {!proto.unpack.v1.ast.NodeType} value + * @return {!proto.unpack.v1.ast.UnarySuffix} returns this + */ +proto.unpack.v1.ast.UnarySuffix.prototype.setKind = function(value) { + return jspb.Message.setProto3EnumField(this, 13, value); +}; + + /** * optional Src src = 3; * @return {?proto.unpack.v1.ast.Src} diff --git a/dist/protosets/unpack.protoset b/dist/protosets/unpack.protoset index add66b05b2d79c20987f92c790c54f6449cd891a..dec90ad9a61163e629113ee82ee5f542ac7022be 100644 GIT binary patch delta 429 zcmeyeMrhAEp@tU5ElerDnAY=5Py5AG%eZ;^lV41s(*wL2IT(4T3$A9=o^Hv@D8D`a zH`9JbrUPu#3%yySr>_@aHk(}kL~QzsI-shkLdI%F)#--yjMCHR3o`RDs!U%e$m~4% z?n`rR5iTAsRu%>(R#qWqeijZGj}ge@y)o5h($ delta 791 zcmeH^yGjE=6oxZ%&Tg`^xopmio9MU+BhReKsayD_>A6+GjeRu?3^HKP_%;+m;1snEW@%MJd8n_K9LfsF;U|2O}4o4*|UFdX}MeEkC( Cd|9#p