Skip to content

Commit

Permalink
Merge pull request apache#151 from piiswrong/master
Browse files Browse the repository at this point in the history
fix conflict with dmlc
  • Loading branch information
piiswrong authored Jul 12, 2016
2 parents 8183d7d + 11dba2e commit 4e63013
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 7 deletions.
8 changes: 8 additions & 0 deletions mshadow/base.h
Original file line number Diff line number Diff line change
Expand Up @@ -198,6 +198,14 @@ extern "C" {
#define MSHADOW_USE_GLOG DMLC_USE_GLOG
#endif // MSHADOW_USE_GLOG

#if DMLC_USE_CXX11
#define MSHADOW_THROW_EXCEPTION noexcept(false)
#define MSHADOW_NO_EXCEPTION noexcept(true)
#else
#define MSHADOW_THROW_EXCEPTION
#define MSHADOW_NO_EXCEPTION
#endif

/*!
* \brief Protected cuda call in mshadow
* \param func Expression to call.
Expand Down
6 changes: 0 additions & 6 deletions mshadow/logging.h
Original file line number Diff line number Diff line change
Expand Up @@ -37,12 +37,6 @@ struct Error : public std::runtime_error {
#define noexcept(a)
#endif

#if DMLC_USE_CXX11
#define DMLC_THROW_EXCEPTION noexcept(false)
#else
#define DMLC_THROW_EXCEPTION
#endif

#if DMLC_USE_GLOG
#include <glog/logging.h>

Expand Down
2 changes: 1 addition & 1 deletion mshadow/random.h
Original file line number Diff line number Diff line change
Expand Up @@ -237,7 +237,7 @@ class Random<gpu, DType> {
this->Seed(seed);
buffer_.Resize(Shape1(kRandBufferSize));
}
~Random(void) DMLC_THROW_EXCEPTION {
~Random(void) MSHADOW_THROW_EXCEPTION {
curandStatus_t status;
status = curandDestroyGenerator(gen_);
CHECK_EQ(status, CURAND_STATUS_SUCCESS) << "Destory CURAND Gen failed";
Expand Down

0 comments on commit 4e63013

Please sign in to comment.