pitrou commented on code in PR #47860:
URL: https://github.com/apache/arrow/pull/47860#discussion_r2447156330


##########
python/pyarrow/src/arrow/python/arrow_to_pandas.h:
##########
@@ -112,11 +128,11 @@ struct PandasOptions {
   bool decode_dictionaries = false;
 
   // Columns that should be casted to categorical
-  std::unordered_set<std::string> categorical_columns;
+  std::shared_ptr<const std::unordered_set<std::string>> categorical_columns;

Review Comment:
   Can we just add a comment to explain the rationale? For example:
   ```suggestion
     //
     // This is wrapped in a shared_ptr because this struct is copied 
internally for
     // each column or nested field (see GH-47861).
     std::shared_ptr<const std::unordered_set<std::string>> categorical_columns;
   ```



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