[glibmm] Revert "Add Glib::c_str_or_null()"



commit bf00b243b3fc7eeb9f952952e86d0c089fb26b18
Author: Kjell Ahlstedt <kjell ahlstedt bredband net>
Date:   Mon Oct 19 18:56:27 2015 +0200

    Revert "Add Glib::c_str_or_null()"
    
    This reverts commit bf69428947398356c86c43e2be4f26dce03583dc.
    
    Let's wait with this commit until there is a better reason
    to branch glibmm-2-46. Didn't notice that master is a stable
    branch right now.

 glib/glibmm/utility.h |    8 --------
 1 files changed, 0 insertions(+), 8 deletions(-)
---
diff --git a/glib/glibmm/utility.h b/glib/glibmm/utility.h
index 696a963..3038dff 100644
--- a/glib/glibmm/utility.h
+++ b/glib/glibmm/utility.h
@@ -109,14 +109,6 @@ std::string convert_return_gchar_ptr_to_stdstring(char* str)
                : std::string();
 }
 
-// Get a pointer to the C style string in a std::string or Glib::ustring,
-// returning nullptr, if the string is empty.
-template <typename T>
-inline const char* c_str_or_null(const T& str)
-{
-  return str.empty() ? nullptr : str.c_str();
-}
-
 // Append type_name to dest, while replacing special characters with '+'.
 void append_canonical_typename(std::string& dest, const char* type_name);
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]