[PATCH] Remove redundant const qualifliers from string_view
Jonathan Wakely
jwakely@redhat.com
Tue Oct 11 14:07:00 GMT 2016
On 11/10/16 11:37 +0100, Jonathan Wakely wrote:
>diff --git a/libstdc++-v3/include/experimental/string_view b/libstdc++-v3/include/experimental/string_view
>index 8cb8c1f..c1dfef0 100644
>--- a/libstdc++-v3/include/experimental/string_view
>+++ b/libstdc++-v3/include/experimental/string_view
>@@ -420,7 +420,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
>
> private:
>
>- static constexpr const int
>+ static constexpr int
> _S_compare(size_type __n1, size_type __n2) noexcept
> {
> return difference_type{__n1 - __n2} > std::numeric_limits<int>::max()
>diff --git a/libstdc++-v3/include/std/string_view b/libstdc++-v3/include/std/string_view
>index 14bfcd0..b2d2a29 100644
>--- a/libstdc++-v3/include/std/string_view
>+++ b/libstdc++-v3/include/std/string_view
>@@ -414,7 +414,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
>
> private:
>
>- static constexpr const int
>+ static constexpr int
> _S_compare(size_type __n1, size_type __n2) noexcept
> {
> return difference_type{__n1 - __n2} > std::numeric_limits<int>::max()
I forgot to say, there are still warnings here due to the narrowing
conversions to difference_type.
More information about the Libstdc++
mailing list