alamb commented on code in PR #9997:
URL: https://github.com/apache/arrow-rs/pull/9997#discussion_r3283554240
##########
parquet/src/parquet_macros.rs:
##########
@@ -260,6 +260,85 @@ macro_rules! thrift_union {
}
}
+/// Macro used to generate Rust enums for Thrift unions where variants are a
mix of unit and
+/// tuple types. This version allows for unknown variants for forwards
compatibility.
+///
+/// Use of this macro requires modifying the thrift IDL. For variants with
empty structs as their
+/// type, delete the typename (i.e. `1: EmptyStruct Var1;` becomes `1: Var1`).
For variants with a
+/// non-empty type, the typename must be contained within parens (e.g. `1:
MyType Var1;` becomes
+/// `1: (MyType) Var1;`).
+///
+/// This macro allows for specifying lifetime annotations for the resulting
`enum` and its fields.
+///
+/// When utilizing this macro the Thrift serialization traits and structs need
to be in scope.
+#[macro_export]
Review Comment:
Claude also pointed out that the other macros in this file are annotated
with `#doc(hidden)` so it might be nice to do the same here for consistency
```suggestion
#[doc(hidden)]
#[macro_export]
```
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]