diff options
author | 2014-02-07 18:19:29 +0100 | |
---|---|---|
committer | 2015-05-03 10:23:09 +0100 | |
commit | 5ed6a23569c2b00e51d952fc1f5511acee70b830 (patch) | |
tree | 89fe6c65b3ee80197348819fc02f08890eb19d86 | |
parent | fe3f71c48c42c17811ad612b00c7006dc57a370c (diff) | |
download | paludis-5ed6a23569c2b00e51d952fc1f5511acee70b830.tar.gz paludis-5ed6a23569c2b00e51d952fc1f5511acee70b830.tar.xz |
Let destringify use a default template argument
Part of C++11 and supported since gcc 4.3
Default template arguments for function templates DR226 GCC 4.3
https://gcc.gnu.org/projects/cxx0x.html
Change-Id: I584af0f6ea26c0d2d0ba0e6221e375270e3019df
-rw-r--r-- | paludis/util/destringify.hh | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/paludis/util/destringify.hh b/paludis/util/destringify.hh index 1a97d014c..11452746a 100644 --- a/paludis/util/destringify.hh +++ b/paludis/util/destringify.hh @@ -151,7 +151,7 @@ namespace paludis * * \ingroup g_strings */ - template <typename Type_, typename Exception_> + template <typename Type_, typename Exception_ = DestringifyError> Type_ destringify(const std::string & s) { if (s == "") @@ -159,12 +159,6 @@ namespace paludis return destringify_internals::Destringifier<Type_, Exception_>::do_destringify(s); } - - template <typename Type_> - Type_ destringify(const std::string & s) - { - return destringify<Type_, DestringifyError>(s); - } } #endif |