summaryrefslogtreecommitdiff
path: root/test/std/utilities
diff options
context:
space:
mode:
Diffstat (limited to 'test/std/utilities')
-rw-r--r--test/std/utilities/memory/storage.iterator/raw_storage_iterator.base.pass.cpp8
-rw-r--r--test/std/utilities/memory/storage.iterator/raw_storage_iterator.pass.cpp7
-rw-r--r--test/std/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.create/allocate_shared.pass.cpp8
-rw-r--r--test/std/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.create/make_shared.pass.cpp9
4 files changed, 32 insertions, 0 deletions
diff --git a/test/std/utilities/memory/storage.iterator/raw_storage_iterator.base.pass.cpp b/test/std/utilities/memory/storage.iterator/raw_storage_iterator.base.pass.cpp
index 62a3be80d..eb66ed4ad 100644
--- a/test/std/utilities/memory/storage.iterator/raw_storage_iterator.base.pass.cpp
+++ b/test/std/utilities/memory/storage.iterator/raw_storage_iterator.base.pass.cpp
@@ -15,6 +15,13 @@
#include "test_macros.h"
+#if TEST_STD_VER >= 11
+#define DELETE_FUNCTION = delete
+#else
+#define DELETE_FUNCTION
+#endif
+
+
int A_constructed = 0;
struct A
@@ -27,6 +34,7 @@ public:
~A() {--A_constructed; data_ = 0;}
bool operator==(int i) const {return data_ == i;}
+ A* operator& () DELETE_FUNCTION;
};
int main()
diff --git a/test/std/utilities/memory/storage.iterator/raw_storage_iterator.pass.cpp b/test/std/utilities/memory/storage.iterator/raw_storage_iterator.pass.cpp
index 3df8dd0ed..4d9d698f7 100644
--- a/test/std/utilities/memory/storage.iterator/raw_storage_iterator.pass.cpp
+++ b/test/std/utilities/memory/storage.iterator/raw_storage_iterator.pass.cpp
@@ -16,6 +16,12 @@
#include "test_macros.h"
#include <MoveOnly.h>
+#if TEST_STD_VER >= 11
+#define DELETE_FUNCTION = delete
+#else
+#define DELETE_FUNCTION
+#endif
+
int A_constructed = 0;
struct A
@@ -28,6 +34,7 @@ public:
~A() {--A_constructed; data_ = 0;}
bool operator==(int i) const {return data_ == i;}
+ A* operator& () DELETE_FUNCTION;
};
int main()
diff --git a/test/std/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.create/allocate_shared.pass.cpp b/test/std/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.create/allocate_shared.pass.cpp
index 3e4a99e98..a430b5d79 100644
--- a/test/std/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.create/allocate_shared.pass.cpp
+++ b/test/std/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.create/allocate_shared.pass.cpp
@@ -23,6 +23,12 @@
#include "test_allocator.h"
#include "min_allocator.h"
+#if TEST_STD_VER >= 11
+#define DELETE_FUNCTION = delete
+#else
+#define DELETE_FUNCTION
+#endif
+
int new_count = 0;
struct A
@@ -37,6 +43,8 @@ struct A
int get_int() const {return int_;}
char get_char() const {return char_;}
+
+ A* operator& () DELETE_FUNCTION;
private:
int int_;
char char_;
diff --git a/test/std/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.create/make_shared.pass.cpp b/test/std/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.create/make_shared.pass.cpp
index f8f73f771..88e691952 100644
--- a/test/std/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.create/make_shared.pass.cpp
+++ b/test/std/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.create/make_shared.pass.cpp
@@ -19,6 +19,12 @@
#include "test_macros.h"
#include "count_new.hpp"
+#if TEST_STD_VER >= 11
+#define DELETE_FUNCTION = delete
+#else
+#define DELETE_FUNCTION
+#endif
+
struct A
{
static int count;
@@ -31,6 +37,9 @@ struct A
int get_int() const {return int_;}
char get_char() const {return char_;}
+
+ A* operator& () DELETE_FUNCTION;
+
private:
int int_;
char char_;