summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStefan Behnel <stefan_ml@behnel.de>2019-01-13 11:46:15 +0100
committerStefan Behnel <stefan_ml@behnel.de>2019-01-13 11:46:15 +0100
commitd2bed7f0f010a9bc6dcf6a042202cecab8f443af (patch)
tree6b4f423ca1af8b8fa4364d74b42b93c5cef4867a
parented7a5bb6c5ebf6e7ec572d748dd249626043294e (diff)
downloadcython-d2bed7f0f010a9bc6dcf6a042202cecab8f443af.tar.gz
Fix initialiser in C++ test: MSVC++ cannot assign statically to non-static members.
-rw-r--r--tests/run/cpp_operators_helper.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/tests/run/cpp_operators_helper.h b/tests/run/cpp_operators_helper.h
index ec77d7f62..6c5a545fe 100644
--- a/tests/run/cpp_operators_helper.h
+++ b/tests/run/cpp_operators_helper.h
@@ -84,10 +84,12 @@ NONMEMBER_BIN_OP2(COMMA)
#define REF_BIN_OP(op) int& operator op (int x) { x++; return value; }
class RefTestOps {
- int value = 0;
+ int value;
public:
+ RefTestOps() { value = 0; }
+
REF_UN_OP(-);
REF_UN_OP(+);
REF_UN_OP(*);