summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKjell Ahlstedt <kjellahlstedt@gmail.com>2022-05-04 16:45:40 +0200
committerKjell Ahlstedt <kjellahlstedt@gmail.com>2022-05-04 16:45:40 +0200
commitcad27382259efc0f1c6e0c9d97ae8f426200fa1a (patch)
tree90df573e885385194d1c1fd1175840ef5ada2b92
parentf3d44e6c9cb1579c1a4e23b70b39edb608792317 (diff)
downloadglibmm-cad27382259efc0f1c6e0c9d97ae8f426200fa1a.tar.gz
Revert "ustring_Iterator: Declare the copy constructor =default"
This reverts commit 7b811a0be824675f31a422d40a75bbb5d10e32ad. It broke ABI. See #98
-rw-r--r--glib/glibmm/ustring.h15
1 files changed, 7 insertions, 8 deletions
diff --git a/glib/glibmm/ustring.h b/glib/glibmm/ustring.h
index 594a2f29..41165f58 100644
--- a/glib/glibmm/ustring.h
+++ b/glib/glibmm/ustring.h
@@ -198,14 +198,7 @@ public:
using pointer = void;
inline ustring_Iterator();
- // A std::string::iterator can be copied to a std::string::const_iterator.
- template <typename T2, typename = typename std::enable_if<
- std::is_same<std::string::const_iterator, T>::value &&
- std::is_same<std::string::iterator, T2>::value, T2>::type>
- inline ustring_Iterator(const ustring_Iterator<T2>& other)
- : pos_(other.base())
- { }
- ustring_Iterator(const ustring_Iterator& other) = default;
+ inline ustring_Iterator(const ustring_Iterator<std::string::iterator>& other);
ustring_Iterator& operator=(const ustring_Iterator& other) = default;
inline value_type operator*() const;
@@ -1074,6 +1067,12 @@ inline ustring_Iterator<T>::ustring_Iterator() : pos_()
}
template <class T>
+inline ustring_Iterator<T>::ustring_Iterator(const ustring_Iterator<std::string::iterator>& other)
+: pos_(other.base())
+{
+}
+
+template <class T>
inline typename ustring_Iterator<T>::value_type ustring_Iterator<T>::operator*() const
{
return Glib::get_unichar_from_std_iterator(pos_);