[gjs: 9/18] jsapi-util: Remove const T* get() overload of GjsAutoPointer
- From: Philip Chimento <pchimento src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gjs: 9/18] jsapi-util: Remove const T* get() overload of GjsAutoPointer
- Date: Fri, 4 Dec 2020 01:18:23 +0000 (UTC)
commit 1193cab72d550dc189085121bdfca3cc3eb0b20f
Author: Philip Chimento <philip chimento gmail com>
Date: Thu Nov 26 19:53:22 2020 -0800
jsapi-util: Remove const T* get() overload of GjsAutoPointer
We only need one of these; the method is const in any case, because it
doesn't modify the auto pointer struct.
gjs/jsapi-util.h | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
---
diff --git a/gjs/jsapi-util.h b/gjs/jsapi-util.h
index ee004037..f43c294d 100644
--- a/gjs/jsapi-util.h
+++ b/gjs/jsapi-util.h
@@ -121,8 +121,7 @@ struct GjsAutoPointer {
constexpr operator ConstPtr() const { return m_ptr; }
constexpr operator bool() const { return m_ptr != nullptr; }
- constexpr Ptr get() { return m_ptr; }
- constexpr ConstPtr get() const { return m_ptr; }
+ constexpr Ptr get() const { return m_ptr; }
constexpr Ptr* out() { return &m_ptr; }
constexpr Ptr release() {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]