diff options
author | Paolo Carlini <paolo.carlini@oracle.com> | 2009-08-07 10:13:44 +0000 |
---|---|---|
committer | Paolo Carlini <paolo@gcc.gnu.org> | 2009-08-07 10:13:44 +0000 |
commit | ac517fcbcc6b466090863ad95300c6ebeccfd0ef (patch) | |
tree | 0f3309c2493e1788c94da391e50a2e33d6967ead | |
parent | 1c939d817555244adf45254697fda25717746c95 (diff) | |
download | gcc-ac517fcbcc6b466090863ad95300c6ebeccfd0ef.zip gcc-ac517fcbcc6b466090863ad95300c6ebeccfd0ef.tar.gz gcc-ac517fcbcc6b466090863ad95300c6ebeccfd0ef.tar.bz2 |
hash.cc (hash<string>::operator()(string), hash<wstring>::operator()(wstring)): Do not decorate as throwing nothing.
2009-08-07 Paolo Carlini <paolo.carlini@oracle.com>
* src/hash.cc (hash<string>::operator()(string),
hash<wstring>::operator()(wstring)): Do not decorate as throwing
nothing.
* include/bits/functional_hash.h (hash<error_code>::
operator()(error_code)): Likewise.
From-SVN: r150566
-rw-r--r-- | libstdc++-v3/ChangeLog | 8 | ||||
-rw-r--r-- | libstdc++-v3/include/bits/functional_hash.h | 4 | ||||
-rw-r--r-- | libstdc++-v3/src/hash.cc | 4 |
3 files changed, 12 insertions, 4 deletions
diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog index c668f53..f6d6f50 100644 --- a/libstdc++-v3/ChangeLog +++ b/libstdc++-v3/ChangeLog @@ -1,3 +1,11 @@ +2009-08-07 Paolo Carlini <paolo.carlini@oracle.com> + + * src/hash.cc (hash<string>::operator()(string), + hash<wstring>::operator()(wstring)): Do not decorate as throwing + nothing. + * include/bits/functional_hash.h (hash<error_code>:: + operator()(error_code)): Likewise. + 2009-08-06 Benjamin Kosnik <bkoz@redhat.com> * src/compatibility.cc: Make C++0x safe, add in explicit casts to diff --git a/libstdc++-v3/include/bits/functional_hash.h b/libstdc++-v3/include/bits/functional_hash.h index c21abfe..78b0aa3 100644 --- a/libstdc++-v3/include/bits/functional_hash.h +++ b/libstdc++-v3/include/bits/functional_hash.h @@ -1,6 +1,6 @@ // functional_hash.h header -*- C++ -*- -// Copyright (C) 2007, 2009 Free Software Foundation, Inc. +// Copyright (C) 2007, 2008, 2009 Free Software Foundation, Inc. // // This file is part of the GNU ISO C++ Library. This library is free // software; you can redistribute it and/or modify it under the @@ -61,7 +61,7 @@ namespace std template<> _GLIBCXX_PURE size_t - hash<error_code>::operator()(error_code) const throw (); + hash<error_code>::operator()(error_code) const; } #endif // _FUNCTIONAL_HASH_H diff --git a/libstdc++-v3/src/hash.cc b/libstdc++-v3/src/hash.cc index 790cfee..2c9c113 100644 --- a/libstdc++-v3/src/hash.cc +++ b/libstdc++-v3/src/hash.cc @@ -72,7 +72,7 @@ _GLIBCXX_BEGIN_NAMESPACE_TR1 #ifndef _GLIBCXX_LONG_DOUBLE_COMPAT_IMPL template<> size_t - hash<string>::operator()(string __s) const throw () + hash<string>::operator()(string __s) const { return _Fnv_hash<>::hash(__s.data(), __s.length()); } template<> @@ -83,7 +83,7 @@ _GLIBCXX_BEGIN_NAMESPACE_TR1 #ifdef _GLIBCXX_USE_WCHAR_T template<> size_t - hash<wstring>::operator()(wstring __s) const throw () + hash<wstring>::operator()(wstring __s) const { const char* __p = reinterpret_cast<const char*>(__s.data()); return _Fnv_hash<>::hash(__p, __s.length() * sizeof(wchar_t)); |