aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/base
diff options
context:
space:
mode:
authorTomasz Frydrych <[email protected]>2017-04-02 22:24:31 +0200
committerTomasz Frydrych <[email protected]>2017-04-03 23:42:29 +0200
commitfbef72e11c483fae16c32480cf84253a56d0ee25 (patch)
tree200b0fe290e9809ef6c8883e886b7c9a48c902a1 /src/lib/base
parent753b4c2d5301574d3c9390b79aa275a49809e6c8 (diff)
Content:
* fixes for deprecated constructions in c++11 and later (explicit rule of 3/5 or implicit rule of 0 and other violations) * `default` specifier instead of `{}` in some places(probably all) * removal of unreachable code (for example `return` after `throw`) * removal of compilation unit only visible, but not used functions * fix for `throw()` specifier - used instead `BOTAN_NOEXCEPT` * removed not needed semicolons
Diffstat (limited to 'src/lib/base')
-rw-r--r--src/lib/base/secmem.h14
1 files changed, 11 insertions, 3 deletions
diff --git a/src/lib/base/secmem.h b/src/lib/base/secmem.h
index 758045c93..3852c5323 100644
--- a/src/lib/base/secmem.h
+++ b/src/lib/base/secmem.h
@@ -46,13 +46,21 @@ class secure_allocator
typedef std::size_t size_type;
typedef std::ptrdiff_t difference_type;
- secure_allocator() BOTAN_NOEXCEPT {}
+#ifdef BOTAN_BUILD_COMPILER_IS_MSVC_2013
+ secure_allocator() = default;
+ secure_allocator(const secure_allocator&) = default;
+ secure_allocator& operator=(const secure_allocator&) = default;
+ ~secure_allocator() = default;
+#else
+ secure_allocator() BOTAN_NOEXCEPT = default;
+ secure_allocator(const secure_allocator&) BOTAN_NOEXCEPT = default;
+ secure_allocator& operator=(const secure_allocator&) BOTAN_NOEXCEPT = default;
+ ~secure_allocator() BOTAN_NOEXCEPT = default;
+#endif
template<typename U>
secure_allocator(const secure_allocator<U>&) BOTAN_NOEXCEPT {}
- ~secure_allocator() BOTAN_NOEXCEPT {}
-
pointer address(reference x) const BOTAN_NOEXCEPT
{ return std::addressof(x); }