You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by "friendlymatthew (via GitHub)" <gi...@apache.org> on 2025/07/11 22:51:16 UTC
Re: [PR] [Variant] Append complex variants [arrow-rs]
friendlymatthew commented on code in PR #7914:
URL: https://github.com/apache/arrow-rs/pull/7914#discussion_r2202020955
##########
parquet-variant/src/builder.rs:
##########
@@ -213,14 +215,14 @@ impl ValueBuffer {
Variant::Binary(v) => self.append_binary(v),
Variant::String(s) => self.append_string(s),
Variant::ShortString(s) => self.append_short_string(s),
- Variant::Object(_) | Variant::List(_) => {
- unreachable!(
- "Nested values are handled specially by ObjectBuilder and ListBuilder"
- );
- }
+ _ => unreachable!("Objects and lists must be appended using VariantBuilder::append_object and VariantBuilder::append_list"),
}
}
+ fn append_non_nested_value<'m, 'd, T: Into<Variant<'m, 'd>>>(&mut self, value: T) {
Review Comment:
maybe a better name would be `append_primitive_value`?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org