apeforest commented on a change in pull request #13922: Support populating 
errors back to MXNet engine in callback
URL: https://github.com/apache/incubator-mxnet/pull/13922#discussion_r248868642
 
 

 ##########
 File path: include/mxnet/engine.h
 ##########
 @@ -74,15 +74,15 @@ class CallbackOnComplete {
  public:
   // use implicit copy and assign
   /*! \brief involve the callback */
-  inline void operator()() const {
-    (*callback_)(engine_, param_);
+  inline void operator()(const char* error_msg = nullptr) const {
 
 Review comment:
   Instead of passing in a const string of error message, would it make sense 
to pass in a `error` struct which contains error message and error code in the 
fields? This leaves more room for proper error handling based on error code.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to