|
|
@ -963,13 +963,15 @@ static void putary(VALUE ary, const upb_fielddef *f, upb_sink *sink, |
|
|
|
|
|
|
|
|
|
|
|
if (ary == Qnil) return; |
|
|
|
if (ary == Qnil) return; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
size = NUM2INT(RepeatedField_length(ary)); |
|
|
|
|
|
|
|
if (size == 0 && !emit_defaults) return; |
|
|
|
|
|
|
|
|
|
|
|
upb_sink_startseq(sink, getsel(f, UPB_HANDLER_STARTSEQ), &subsink); |
|
|
|
upb_sink_startseq(sink, getsel(f, UPB_HANDLER_STARTSEQ), &subsink); |
|
|
|
|
|
|
|
|
|
|
|
if (upb_fielddef_isprimitive(f)) { |
|
|
|
if (upb_fielddef_isprimitive(f)) { |
|
|
|
sel = getsel(f, upb_handlers_getprimitivehandlertype(f)); |
|
|
|
sel = getsel(f, upb_handlers_getprimitivehandlertype(f)); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
size = NUM2INT(RepeatedField_length(ary)); |
|
|
|
|
|
|
|
for (int i = 0; i < size; i++) { |
|
|
|
for (int i = 0; i < size; i++) { |
|
|
|
void* memory = RepeatedField_index_native(ary, i); |
|
|
|
void* memory = RepeatedField_index_native(ary, i); |
|
|
|
switch (type) { |
|
|
|
switch (type) { |
|
|
|