This is the mail archive of the
gcc-prs@gcc.gnu.org
mailing list for the GCC project.
libstdc++/4539: locale::combine should be const
- To: gcc-gnats at gcc dot gnu dot org
- Subject: libstdc++/4539: locale::combine should be const
- From: brendan at zen dot org
- Date: 11 Oct 2001 14:08:05 -0000
- Reply-To: brendan at zen dot org
>Number: 4539
>Category: libstdc++
>Synopsis: locale::combine should be const
>Confidential: no
>Severity: serious
>Priority: low
>Responsible: unassigned
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Thu Oct 11 07:16:01 PDT 2001
>Closed-Date:
>Last-Modified:
>Originator: Brendan Kehoe
>Release: CVS tree
>Organization:
>Environment:
>Description:
Library DR #14 includes the change that locale::combine should be const; the attached patch includes that change in both localefwd.h and locale_facets.tcc.
>How-To-Repeat:
>Fix:
>Release-Note:
>Audit-Trail:
>Unformatted:
----gnatsweb-attachment----
Content-Type: text/plain; name="diffs-locale_facets.txt"
Content-Disposition: inline; filename="diffs-locale_facets.txt"
2001-10-10 Brendan Kehoe <brendan@zen.org>
* bits/localefwd.h (locale::combine): Add const for lib DR 14.
* bits/locale_facets.tcc (locale::combine): Likewise.
Index: include/bits/locale_facets.tcc
===================================================================
RCS file: /cvs/gcc/egcs/libstdc++-v3/include/bits/locale_facets.tcc,v
retrieving revision 1.29
diff -u -p -r1.29 locale_facets.tcc
--- locale_facets.tcc 2001/10/02 18:44:39 1.29
+++ locale_facets.tcc 2001/10/10 11:44:22
@@ -46,7 +46,7 @@ namespace std
{
template<typename _Facet>
locale
- locale::combine(const locale& __other)
+ locale::combine(const locale& __other) const
{
_Impl* __tmp = new _Impl(*_M_impl, 1);
__tmp->_M_replace_facet(__other._M_impl, &_Facet::id);
Index: include/bits/localefwd.h
===================================================================
RCS file: /cvs/gcc/egcs/libstdc++-v3/include/bits/localefwd.h,v
retrieving revision 1.19
diff -u -p -r1.19 localefwd.h
--- localefwd.h 2001/09/20 08:30:00 1.19
+++ localefwd.h 2001/10/10 11:44:23
@@ -234,7 +234,7 @@ namespace std
template<typename _Facet>
locale
- combine(const locale& __other);
+ combine(const locale& __other) const;
// Locale operations:
string