[libsigc++2] Remove now-unnecessary SIGC_CXX_HAS_NAMESPACE_STD() configure check.



commit 801bb2c67845538e1b80669681b1eb1c4a6994a7
Author: Murray Cumming <murrayc murrayc com>
Date:   Thu Mar 3 12:44:22 2016 +0100

    Remove now-unnecessary SIGC_CXX_HAS_NAMESPACE_STD() configure check.
    
    Bug #762065 (Kjell Ahlstedt)

 build/cxx_std.m4           |   44 --------------------------------------------
 configure.ac               |    1 -
 docs/reference/Doxyfile.in |    4 +---
 sigc++config.h.in          |   10 ----------
 4 files changed, 1 insertions(+), 58 deletions(-)
---
diff --git a/build/cxx_std.m4 b/build/cxx_std.m4
index 8ef9548..e902c55 100644
--- a/build/cxx_std.m4
+++ b/build/cxx_std.m4
@@ -1,42 +1,3 @@
-cv_cxx_has_namespace_std
-## SIGC_CXX_HAS_NAMESPACE_STD()
-##
-## Test whether libstdc++ declares namespace std.  For safety,
-## also check whether several randomly selected STL symbols
-## are available in namespace std.
-##
-## On success, #define SIGC_HAVE_NAMESPACE_STD to 1.
-##
-AC_DEFUN([SIGC_CXX_HAS_NAMESPACE_STD],
-[
-  AC_CACHE_CHECK(
-    [whether C++ library symbols are declared in namespace std],
-    [sigc_cv_cxx_has_namespace_std],
-  [
-    AC_COMPILE_IFELSE([AC_LANG_PROGRAM(
-    [[
-      #include <algorithm>
-      #include <iterator>
-      #include <iostream>
-      #include <string>
-    ]],[[
-      using std::min;
-      using std::find;
-      using std::copy;
-      using std::bidirectional_iterator_tag;
-      using std::string;
-      using std::istream;
-      using std::cout;
-    ]])],
-      [sigc_cv_cxx_has_namespace_std='yes'],
-      [sigc_cv_cxx_has_namespace_std='no']
-    )
-  ])
-
-  AS_IF([test "x${sigc_cv_cxx_has_namespace_std}" = 'xyes'],
-  [AC_DEFINE([SIGC_HAVE_NAMESPACE_STD],[1], [Defined when the libstdc++ declares the std-namespace])])
-])
-
 ## SIGC_CXX_HAS_SUN_REVERSE_ITERATOR()
 ##
 ## Check for Sun libCstd style std::reverse_iterator, which demands more than just one template parameter.
@@ -44,8 +5,6 @@ AC_DEFUN([SIGC_CXX_HAS_NAMESPACE_STD],
 ##
 AC_DEFUN([SIGC_CXX_HAS_SUN_REVERSE_ITERATOR],
 [
-  AC_REQUIRE([SIGC_CXX_HAS_NAMESPACE_STD])
-
   AC_CACHE_CHECK(
     [for non-standard Sun libCstd reverse_iterator],
     [sigc_cv_cxx_has_sun_reverse_iterator],
@@ -53,9 +12,6 @@ AC_DEFUN([SIGC_CXX_HAS_SUN_REVERSE_ITERATOR],
     AC_COMPILE_IFELSE([AC_LANG_PROGRAM(
     [[
       #include <iterator>
-      #ifdef SIGC_HAVE_NAMESPACE_STD
-      using namespace std;
-      #endif
     ]],[[
       typedef reverse_iterator<char*,random_access_iterator_tag,char,char&,char*,int> ReverseIter;
     ]])],
diff --git a/configure.ac b/configure.ac
index 5fb4ec6..d89b139 100644
--- a/configure.ac
+++ b/configure.ac
@@ -53,7 +53,6 @@ AC_LANG([C++])
 SIGC_CXX_GCC_TEMPLATE_SPECIALIZATION_OPERATOR_OVERLOAD
 SIGC_CXX_MSVC_TEMPLATE_SPECIALIZATION_OPERATOR_OVERLOAD
 SIGC_CXX_PRAGMA_PUSH_POP_MACRO
-SIGC_CXX_HAS_NAMESPACE_STD
 SIGC_CXX_HAS_SUN_REVERSE_ITERATOR
 
 AS_IF([test "x$config_error" = xyes],
diff --git a/docs/reference/Doxyfile.in b/docs/reference/Doxyfile.in
index 64de25b..3909fac 100644
--- a/docs/reference/Doxyfile.in
+++ b/docs/reference/Doxyfile.in
@@ -280,10 +280,8 @@ PREDEFINED             = __cplusplus \
                          "SIGC_API=" \
                          SIGC_CONFIGURE \
                          SIGC_GCC_TEMPLATE_SPECIALIZATION_OPERATOR_OVERLOAD \
-                         SIGC_HAVE_NAMESPACE_STD \
                          SIGC_MSVC_TEMPLATE_SPECIALIZATION_OPERATOR_OVERLOAD \
-                         SIGC_TEMPLATE_SPECIALIZATION_OPERATOR_OVERLOAD \
-                         "SIGC_USING_STD(Symbol)="
+                         SIGC_TEMPLATE_SPECIALIZATION_OPERATOR_OVERLOAD"
 EXPAND_AS_DEFINED      = SIGC_WORKAROUND_OPERATOR_PARENTHESES \
                          SIGCXX_MAJOR_VERSION \
                          SIGCXX_MINOR_VERSION \
diff --git a/sigc++config.h.in b/sigc++config.h.in
index 1576e03..2222855 100644
--- a/sigc++config.h.in
+++ b/sigc++config.h.in
@@ -46,7 +46,6 @@
 
 # define SIGC_MSVC_TEMPLATE_SPECIALIZATION_OPERATOR_OVERLOAD 1
 # define SIGC_NEW_DELETE_IN_LIBRARY_ONLY 1 /* To keep ABI compatibility */
-# define SIGC_HAVE_NAMESPACE_STD 1
 # define SIGC_PRAGMA_PUSH_POP_MACRO 1
 
 #if (_MSC_VER < 1900) && !defined (noexcept)
@@ -60,9 +59,6 @@
    calling operator() template methods. */
 # undef SIGC_GCC_TEMPLATE_SPECIALIZATION_OPERATOR_OVERLOAD
 
-/* Defined when the libstdc++ declares the std-namespace */
-# undef SIGC_HAVE_NAMESPACE_STD
-
 /* Define if the non-standard Sun reverse_iterator must be used. */
 # undef SIGC_HAVE_SUN_REVERSE_ITERATOR
 
@@ -75,12 +71,6 @@
 
 #endif /* !SIGC_MSC */
 
-#ifdef SIGC_HAVE_NAMESPACE_STD
-# define SIGC_USING_STD(Symbol) /* empty */
-#else
-# define SIGC_USING_STD(Symbol) namespace std { using ::Symbol; }
-#endif
-
 #ifdef SIGC_DLL
 # if defined(SIGC_BUILD) && defined(_WINDLL)
 #  define SIGC_API __declspec(dllexport)


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