Skip to content

Commit 9e298ea

Browse files
committed
build: eliminate c++17 Python build warning
1 parent 65ba2e0 commit 9e298ea

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

modules/python/src2/cv2.cpp

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,13 @@
11
#if defined(_MSC_VER) && (_MSC_VER >= 1800)
22
// eliminating duplicated round() declaration
33
#define HAVE_ROUND 1
4+
#pragma warning(push)
5+
#pragma warning(disable:5033) // 'register' is no longer a supported storage class
46
#endif
5-
67
#include <Python.h>
8+
#if defined(_MSC_VER) && (_MSC_VER >= 1800)
9+
#pragma warning(pop)
10+
#endif
711

812
#define MODULESTR "cv2"
913
#define NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION

0 commit comments

Comments
 (0)