Taepper commented on code in PR #46926:
URL: https://github.com/apache/arrow/pull/46926#discussion_r2720541424


##########
c_glib/arrow-glib/compute.cpp:
##########
@@ -4357,7 +4425,8 @@ garrow_rank_options_get_property(GObject *object,
 
   switch (prop_id) {
   case PROP_RANK_OPTIONS_NULL_PLACEMENT:
-    g_value_set_enum(value, 
static_cast<GArrowNullPlacement>(options->null_placement));
+    g_value_set_enum(value,
+                     
garrow_optional_null_placement_from_raw(options->null_placement));

Review Comment:
   Likewise a `static_cast` needs to be inserted:
   
   ```
       if (options->null_placement.has_value()) {
         g_value_set_enum(value, 
static_cast<GArrowOptionalNullPlacement>(options->null_placement.value()));
       } else {
         g_value_set_enum(value, GARROW_OPTIONAL_NULL_PLACEMENT_UNSPECIFIED);
       }
   ```
   
   Again I could then replace all usages of 
`garrow_optional_null_placement_from_raw` with a construct like this.



-- 
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]

Reply via email to