indigophox commented on code in PR #34817:
URL: https://github.com/apache/arrow/pull/34817#discussion_r1380651557


##########
cpp/src/arrow/flight/types.cc:
##########
@@ -463,6 +463,300 @@ arrow::Result<CancelFlightInfoRequest> 
CancelFlightInfoRequest::Deserialize(
   return out;
 }
 
+// Helper for stringifying maps containing various types
+template <typename T>
+ostream& operator<<(std::map<std::string, T>) {
+  std::stringstream ss;
+
+  ss << '{';
+  std::string sep = "";
+  for (const auto& [k, v] : session_options) {
+    std::cout << sep << '[' << k << "]: '" << v << "', ";  // PHOXME 
v.ToString() not implemented yet
+    sep = ", ";
+  }
+  ss << '}';
+
+  return ss.str();
+}
+static bool CompareSessionOptionMaps(

Review Comment:
   It's forcing a check of the variant type index, operator== will ignore that 
and only test arithmetic value equality which is not sufficient here.  We do 
fall through to using operator== for std::vector<std::string> variant type 
because that's correct.



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