From 887444cee2f3c26867a8cc8250df888b27bb6c72 Mon Sep 17 00:00:00 2001
From: bkoz <bkoz@138bc75d-0d04-0410-961f-82ee72b054a4>
Date: Tue, 7 Nov 2006 12:33:20 +0000
Subject: [PATCH] 2006-11-07  Benjamin Kosnik  <bkoz@redhat.com>

	* include/ext/pb_ds/exception.hpp: Add translation support to
	exception strings.
	* include/ext/concurrence.h: Same.
	* include/tr1/array: Same.



git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@118543 138bc75d-0d04-0410-961f-82ee72b054a4
---
 libstdc++-v3/ChangeLog                       | 7 +++++++
 libstdc++-v3/include/ext/concurrence.h       | 8 ++++----
 libstdc++-v3/include/ext/pb_ds/exception.hpp | 3 ++-
 libstdc++-v3/include/tr1/array               | 8 ++++----
 4 files changed, 17 insertions(+), 9 deletions(-)

diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog
index 7b94c3b8cf7f..374fbf6a50da 100644
--- a/libstdc++-v3/ChangeLog
+++ b/libstdc++-v3/ChangeLog
@@ -1,3 +1,10 @@
+2006-11-07  Benjamin Kosnik  <bkoz@redhat.com>
+
+	* include/ext/pb_ds/exception.hpp: Add translation support to
+	exception strings.
+	* include/ext/concurrence.h: Same.
+	* include/tr1/array: Same.
+
 2006-11-05  Paolo Carlini  <pcarlini@suse.de>
 
 	* docs/html/ext/lwg-active.html, lwg-defects.html: Import Revision 45.
diff --git a/libstdc++-v3/include/ext/concurrence.h b/libstdc++-v3/include/ext/concurrence.h
index 5f71115293bb..a19ba8eef4b4 100644
--- a/libstdc++-v3/include/ext/concurrence.h
+++ b/libstdc++-v3/include/ext/concurrence.h
@@ -93,7 +93,7 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
       if (__gthread_active_p())
 	{
 	  if (__gthread_mutex_lock(&_M_mutex) != 0)
-	    std::__throw_runtime_error("__mutex::lock");
+	    std::__throw_runtime_error(__N("__mutex::lock"));
 	}
 #endif
     }
@@ -104,7 +104,7 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
       if (__gthread_active_p())
 	{
 	  if (__gthread_mutex_unlock(&_M_mutex) != 0)
-	    std::__throw_runtime_error("__mutex::unlock");
+	    std::__throw_runtime_error(__N("__mutex::unlock"));
 	}
 #endif
     }
@@ -140,7 +140,7 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
       if (__gthread_active_p())
 	{
 	  if (__gthread_recursive_mutex_lock(&_M_mutex) != 0)
-	    std::__throw_runtime_error("__recursive_mutex::lock");
+	    std::__throw_runtime_error(__N("__recursive_mutex::lock"));
 	}
 #endif
     }
@@ -151,7 +151,7 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
       if (__gthread_active_p())
 	{
 	  if (__gthread_recursive_mutex_unlock(&_M_mutex) != 0)
-	    std::__throw_runtime_error("__recursive_mutex::unlock");
+	    std::__throw_runtime_error(__N("__recursive_mutex::unlock"));
 	}
 #endif
     }
diff --git a/libstdc++-v3/include/ext/pb_ds/exception.hpp b/libstdc++-v3/include/ext/pb_ds/exception.hpp
index be61d21a55f6..4d1b05394569 100644
--- a/libstdc++-v3/include/ext/pb_ds/exception.hpp
+++ b/libstdc++-v3/include/ext/pb_ds/exception.hpp
@@ -54,7 +54,8 @@ namespace pb_ds
   // Base class for exceptions.
   struct container_error : public std::logic_error
   {
-    container_error() : std::logic_error("data structure exception") { }
+    container_error() 
+    : std::logic_error(__N("policy based data structure exception")) { }
   };
 
   // An entry cannot be inserted into a container object for logical
diff --git a/libstdc++-v3/include/tr1/array b/libstdc++-v3/include/tr1/array
index 1afd7db04a42..adf0e76c2488 100644
--- a/libstdc++-v3/include/tr1/array
+++ b/libstdc++-v3/include/tr1/array
@@ -164,7 +164,7 @@ _GLIBCXX_BEGIN_NAMESPACE(tr1)
         _M_at(size_type __n)
         {
 	  if (__builtin_expect(__n >= _Mm, false))
-	    std::__throw_out_of_range("array::_M_at");
+	    std::__throw_out_of_range(__N("array::_M_at"));
 	  return _M_instance[__n];
 	}
 
@@ -173,7 +173,7 @@ _GLIBCXX_BEGIN_NAMESPACE(tr1)
         typename __gnu_cxx::__enable_if<!_Mm, reference>::__type
         _M_at(size_type)
         {
-	  std::__throw_out_of_range("array::_M_at");
+	  std::__throw_out_of_range(__N("array::_M_at"));
 	  return _M_instance[0];
 	}
 
@@ -182,7 +182,7 @@ _GLIBCXX_BEGIN_NAMESPACE(tr1)
         _M_at(size_type __n) const
         {
 	  if (__builtin_expect(__n >= _Mm, false))
-	    std::__throw_out_of_range("array::_M_at");
+	    std::__throw_out_of_range(__N("array::_M_at"));
 	  return _M_instance[__n];
 	}
 
@@ -190,7 +190,7 @@ _GLIBCXX_BEGIN_NAMESPACE(tr1)
         typename __gnu_cxx::__enable_if<!_Mm, const_reference>::__type
         _M_at(size_type) const
         {
-	  std::__throw_out_of_range("array::_M_at");
+	  std::__throw_out_of_range(__N("array::_M_at"));
 	  return _M_instance[0];
 	}     
     };
-- 
GitLab