pitrou commented on a change in pull request #8264:
URL: https://github.com/apache/arrow/pull/8264#discussion_r495106328



##########
File path: cpp/src/arrow/testing/gtest_util.h
##########
@@ -108,9 +108,9 @@
   } while (false);
 
 #define ASSIGN_OR_HANDLE_ERROR_IMPL(handle_error, status_name, lhs, rexpr) \
-  auto status_name = (rexpr);                                              \
+  auto&& status_name = (rexpr);                                            \
   handle_error(status_name.status());                                      \
-  lhs = std::move(status_name).ValueOrDie();
+  lhs = std::move(status_name).ValueUnsafe();

Review comment:
       Isn't this a problem with `EXPECT_OK_AND_ASSIGN`? Basically `lhs` will 
get some undetermined 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.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to