Unverified Commit ac288eaf authored by Francisco Massa's avatar Francisco Massa Committed by GitHub
Browse files

Remove noexcept from cuda_version (#3091)

Operator registration of functions with noexcept doesn't work on some compilers, see https://github.com/pytorch/pytorch/issues/48667
parent 21deb4d0
...@@ -26,7 +26,7 @@ PyMODINIT_FUNC PyInit__C(void) { ...@@ -26,7 +26,7 @@ PyMODINIT_FUNC PyInit__C(void) {
#endif #endif
namespace vision { namespace vision {
int64_t cuda_version() noexcept { int64_t cuda_version() {
#ifdef WITH_CUDA #ifdef WITH_CUDA
return CUDA_VERSION; return CUDA_VERSION;
#else #else
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
#include "macros.h" #include "macros.h"
namespace vision { namespace vision {
VISION_API int64_t cuda_version() noexcept; VISION_API int64_t cuda_version();
namespace detail { namespace detail {
// Dummy variable to reference a symbol from vision.cpp. // Dummy variable to reference a symbol from vision.cpp.
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment