File tree 1 file changed +1
-30
lines changed
protobuf-codegen/src/gen/field
1 file changed +1
-30
lines changed Original file line number Diff line number Diff line change @@ -188,36 +188,7 @@ impl<'a> FieldGen<'a> {
188
188
189
189
FieldKind :: Repeated ( RepeatedField {
190
190
elem,
191
- packed : field
192
- . field
193
- . proto ( )
194
- . options
195
- . get_or_default ( )
196
- . packed
197
- . unwrap_or ( match field. message . scope . file_scope . syntax ( ) {
198
- Syntax :: Proto2 => false ,
199
- // in proto3, repeated primitive types are packed by default
200
- Syntax :: Proto3 => match field. field . proto ( ) . type_ ( ) {
201
- Type :: TYPE_DOUBLE
202
- | Type :: TYPE_FLOAT
203
- | Type :: TYPE_INT64
204
- | Type :: TYPE_UINT64
205
- | Type :: TYPE_INT32
206
- | Type :: TYPE_FIXED64
207
- | Type :: TYPE_FIXED32
208
- | Type :: TYPE_BOOL
209
- | Type :: TYPE_UINT32
210
- | Type :: TYPE_SFIXED32
211
- | Type :: TYPE_SFIXED64
212
- | Type :: TYPE_SINT32
213
- | Type :: TYPE_SINT64 => true ,
214
- Type :: TYPE_STRING
215
- | Type :: TYPE_GROUP
216
- | Type :: TYPE_MESSAGE
217
- | Type :: TYPE_BYTES
218
- | Type :: TYPE_ENUM => false ,
219
- } ,
220
- } ) ,
191
+ packed : field. field . proto ( ) . options . get_or_default ( ) . packed ( ) ,
221
192
} )
222
193
}
223
194
RuntimeFieldType :: Singular ( ..) => {
You can’t perform that action at this time.
0 commit comments