Skip to content

Commit

Permalink
Handle pushing None in Dense unions
Browse files Browse the repository at this point in the history
  • Loading branch information
jleibs committed May 8, 2023
1 parent bef07b9 commit c35d769
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion arrow2_convert_derive/src/derive_enum.rs
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,6 @@ pub fn expand_serialize(input: DeriveEnum) -> TokenStream {
..
} = (&input).into();

let first_variant = &variant_names[0];
let is_dense = input.is_dense;

let mutable_array_name = &input.common.mutable_array_name();
Expand Down Expand Up @@ -227,6 +226,7 @@ pub fn expand_serialize(input: DeriveEnum) -> TokenStream {
let first_name = &variant_names[0];
quote! {
self.types.push(0);
self.offsets.push((self.#first_name.len()) as i32);
<#first_array_type as MutableArray>::push_null(&mut self.#first_name);
}
} else {
Expand Down

0 comments on commit c35d769

Please sign in to comment.