[gtkmm/gtkmm-2-24] Gdk::ScopedPtr: Don't require a C++11 compiler
- From: Kjell Ahlstedt <kjellahl src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtkmm/gtkmm-2-24] Gdk::ScopedPtr: Don't require a C++11 compiler
- Date: Tue, 31 May 2016 07:08:23 +0000 (UTC)
commit 31e7507ca926eaedeb9c6f990db3e9f114c51a49
Author: Kjell Ahlstedt <kjell ahlstedt bredband net>
Date: Tue May 31 09:06:45 2016 +0200
Gdk::ScopedPtr: Don't require a C++11 compiler
* gdk/src/types.hg: Don't use the C++11-specific nullptr and noexcept.
https://mail.gnome.org/archives/gtkmm-list/2016-May/msg00021.html
gdk/src/types.hg | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/gdk/src/types.hg b/gdk/src/types.hg
index bb75c68..ed3a783 100644
--- a/gdk/src/types.hg
+++ b/gdk/src/types.hg
@@ -145,9 +145,9 @@ private:
ScopedPtr<T>& operator=(const ScopedPtr<T>&);
public:
- ScopedPtr() : ptr_(nullptr) {}
+ ScopedPtr() : ptr_(0) {}
explicit ScopedPtr(T* ptr) : ptr_(ptr) {}
- ~ScopedPtr() noexcept { g_free(ptr_); }
+ ~ScopedPtr() { g_free(ptr_); }
T* get() const { return ptr_; }
T** addr() { return &ptr_; }
};
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]