|
140 | 140 | template<class Facet> locale combine(const locale& other) const; |
141 | 141 |
|
142 | 142 | // locale operations |
143 | | - basic_string<char> name() const; |
| 143 | + string name() const; |
144 | 144 |
|
145 | 145 | bool operator==(const locale& other) const; |
146 | 146 |
|
|
573 | 573 | \end{itemdecl} |
574 | 574 |
|
575 | 575 | \begin{itemdescr} |
576 | | -\pnum |
577 | | -Default constructor: a snapshot of the current global locale. |
578 | | - |
579 | 576 | \pnum |
580 | 577 | \effects |
581 | 578 | Constructs a copy of the argument last passed to |
|
584 | 581 | function semantics identical to those of |
585 | 582 | \tcode{locale::classic()}. |
586 | 583 | \begin{note} |
587 | | -This constructor is commonly used as the default value for arguments |
588 | | -of functions that take a |
589 | | -\tcode{const locale\&} |
590 | | -argument. |
| 584 | +This constructor yields a copy of the current global locale. |
| 585 | +It is commonly used as a default argument for |
| 586 | +function parameters of type \tcode{const locale\&}. |
591 | 587 | \end{note} |
592 | 588 | \end{itemdescr} |
593 | 589 |
|
594 | | -\indexlibraryctor{locale}% |
595 | | -\begin{itemdecl} |
596 | | -locale(const locale& other) noexcept; |
597 | | -\end{itemdecl} |
598 | | - |
599 | | -\begin{itemdescr} |
600 | | -\pnum |
601 | | -\effects |
602 | | -Constructs a locale which is a copy of \tcode{other}. |
603 | | -\end{itemdescr} |
604 | | - |
605 | 590 | \indexlibraryctor{locale}% |
606 | 591 | \begin{itemdecl} |
607 | 592 | explicit locale(const char* std_name); |
|
728 | 713 | \tcode{*this}. |
729 | 714 | \end{itemdescr} |
730 | 715 |
|
731 | | -\indexlibrarydtor{locale}% |
732 | | -\begin{itemdecl} |
733 | | -~locale(); |
734 | | -\end{itemdecl} |
735 | | - |
736 | | -\begin{itemdescr} |
737 | | -\pnum |
738 | | -A non-virtual destructor that throws no exceptions. |
739 | | -\end{itemdescr} |
740 | | - |
741 | 716 | \rSec3[locale.members]{Members} |
742 | 717 |
|
743 | 718 | \indexlibrarymember{locale}{combine}% |
|
774 | 749 |
|
775 | 750 | \indexlibrarymember{locale}{name}% |
776 | 751 | \begin{itemdecl} |
777 | | -basic_string<char> name() const; |
| 752 | +string name() const; |
778 | 753 | \end{itemdecl} |
779 | 754 |
|
780 | 755 | \begin{itemdescr} |
|
852 | 827 | \end{itemdecl} |
853 | 828 |
|
854 | 829 | \begin{itemdescr} |
855 | | -\pnum |
856 | | -Sets the global locale to its argument. |
857 | | - |
858 | 830 | \pnum |
859 | 831 | \effects |
| 832 | +Sets the global locale to its argument. |
860 | 833 | Causes future calls to the constructor |
861 | 834 | \tcode{locale()} |
862 | 835 | to return a copy of the argument. |
|
866 | 839 | \end{codeblock} |
867 | 840 | otherwise, the effect on the C locale, if any, is \impldef{effect on C locale of calling |
868 | 841 | \tcode{locale::global}}. |
| 842 | + |
| 843 | +\pnum |
| 844 | +\remarks |
869 | 845 | No library function other than |
870 | 846 | \tcode{locale::global()} |
871 | | -shall affect the value returned by |
| 847 | +affects the value returned by |
872 | 848 | \tcode{locale()}. |
873 | 849 | \begin{note} |
874 | 850 | See~\ref{c.locales} for data race considerations when |
|
910 | 886 |
|
911 | 887 | \begin{itemdescr} |
912 | 888 | \pnum |
913 | | -\requires |
| 889 | +\mandates |
914 | 890 | \tcode{Facet} |
915 | 891 | is a facet class whose definition contains the public static member |
916 | 892 | \tcode{id} |
|
1605 | 1581 |
|
1606 | 1582 | \begin{itemdescr} |
1607 | 1583 | \pnum |
1608 | | -\requires |
1609 | | -\tcode{tbl} either 0 or an array of at least |
1610 | | -\tcode{table_size} |
1611 | | -elements. |
| 1584 | +\expects |
| 1585 | +Either \tcode{tbl == nullptr} is \tcode{true} or \range{tbl}{tbl+table_size} is a valid range. |
1612 | 1586 |
|
1613 | 1587 | \pnum |
1614 | 1588 | \effects |
|
2001 | 1975 |
|
2002 | 1976 | \begin{itemdescr} |
2003 | 1977 | \pnum |
2004 | | -\requires |
2005 | | -\tcode{(from <= from_end \&\& to <= to_end)} |
2006 | | -well-defined and |
2007 | | -\tcode{true}; |
2008 | | -\tcode{state} initialized, if at the beginning of a sequence, or else equal to |
2009 | | -the result of converting the preceding characters in the sequence. |
| 1978 | +\expects |
| 1979 | +\tcode{(from <= from_end \&\& to <= to_end)} is well-defined and \tcode{true}; |
| 1980 | +\tcode{state} is initialized, if at the beginning of a sequence, |
| 1981 | +or else is equal to the result of converting the preceding characters in the sequence. |
2010 | 1982 |
|
2011 | 1983 | \pnum |
2012 | 1984 | \effects |
|
2122 | 2094 |
|
2123 | 2095 | \begin{itemdescr} |
2124 | 2096 | \pnum |
2125 | | -\requires |
2126 | | -\tcode{(to <= to_end)} |
2127 | | -well-defined and \tcode{true}; state initialized, if at the beginning of a sequence, |
2128 | | -or else equal to the result of converting the preceding characters in the |
| 2097 | +\expects |
| 2098 | +\tcode{(to <= to_end)} is well-defined and \tcode{true}; |
| 2099 | +\tcode{state} is initialized, if at the beginning of a sequence, |
| 2100 | +or else is equal to the result of converting the preceding characters in the |
2129 | 2101 | sequence. |
2130 | 2102 |
|
2131 | 2103 | \pnum |
|
2202 | 2174 |
|
2203 | 2175 | \begin{itemdescr} |
2204 | 2176 | \pnum |
2205 | | -\requires |
2206 | | -\tcode{(from <= from_end)} |
2207 | | -well-defined and |
2208 | | -\tcode{true}; |
2209 | | -\tcode{state} initialized, if at the beginning of a sequence, or else equal to |
2210 | | -the result of converting the preceding characters in the sequence. |
| 2177 | +\expects |
| 2178 | +\tcode{(from <= from_end)} is well-defined and \tcode{true}; |
| 2179 | +\tcode{state} is initialized, if at the beginning of a sequence, |
| 2180 | +or else is equal to the result of converting the preceding characters in the sequence. |
2211 | 2181 |
|
2212 | 2182 | \pnum |
2213 | 2183 | \effects |
2214 | | -The effect on the \tcode{state} argument is ``as if'' it called |
| 2184 | +The effect on the \tcode{state} argument is as if it called |
2215 | 2185 | \tcode{do_in(state, from, from_end, from, to, to+max, to)} |
2216 | 2186 | for \tcode{to} pointing to a buffer of at least \tcode{max} elements. |
2217 | 2187 |
|
|
3249 | 3219 | \begin{itemdescr} |
3250 | 3220 | \pnum |
3251 | 3221 | \returns |
3252 | | -A basic_string<char> \tcode{vec} used as a vector of integer values, |
| 3222 | +A \tcode{string} \tcode{vec} used as a vector of integer values, |
3253 | 3223 | in which each element |
3254 | 3224 | \tcode{vec[i]} |
3255 | 3225 | represents the number of digits\footnote{Thus, the string |
|
3677 | 3647 |
|
3678 | 3648 | \begin{itemdescr} |
3679 | 3649 | \pnum |
3680 | | -\requires \range{fmt}{fmtend} shall be a valid range. |
| 3650 | +\expects |
| 3651 | +\range{fmt}{fmtend} is a valid range. |
3681 | 3652 |
|
3682 | 3653 | \pnum |
3683 | 3654 | \effects |
|
3882 | 3853 |
|
3883 | 3854 | \begin{itemdescr} |
3884 | 3855 | \pnum |
3885 | | -\requires |
3886 | | -\tcode{t} shall point to an object. |
| 3856 | +\expects |
| 3857 | +\tcode{t} points to an object. |
3887 | 3858 |
|
3888 | 3859 | \pnum |
3889 | 3860 | \effects |
|
4861 | 4832 |
|
4862 | 4833 | explicit messages(size_t refs = 0); |
4863 | 4834 |
|
4864 | | - catalog open(const basic_string<char>& fn, const locale&) const; |
| 4835 | + catalog open(const string& fn, const locale&) const; |
4865 | 4836 | string_type get(catalog c, int set, int msgid, |
4866 | 4837 | const string_type& dfault) const; |
4867 | 4838 | void close(catalog c) const; |
|
4870 | 4841 |
|
4871 | 4842 | protected: |
4872 | 4843 | ~messages(); |
4873 | | - virtual catalog do_open(const basic_string<char>&, const locale&) const; |
| 4844 | + virtual catalog do_open(const string&, const locale&) const; |
4874 | 4845 | virtual string_type do_get(catalog, int set, int msgid, |
4875 | 4846 | const string_type& dfault) const; |
4876 | 4847 | virtual void do_close(catalog) const; |
|
4892 | 4863 |
|
4893 | 4864 | \indexlibrarymember{messages}{open}% |
4894 | 4865 | \begin{itemdecl} |
4895 | | -catalog open(const basic_string<char>& name, const locale& loc) const; |
| 4866 | +catalog open(const string& name, const locale& loc) const; |
4896 | 4867 | \end{itemdecl} |
4897 | 4868 |
|
4898 | 4869 | \begin{itemdescr} |
|
4928 | 4899 |
|
4929 | 4900 | \indexlibrarymember{messages}{do_open}% |
4930 | 4901 | \begin{itemdecl} |
4931 | | -catalog do_open(const basic_string<char>& name, const locale& loc) const; |
| 4902 | +catalog do_open(const string& name, const locale& loc) const; |
4932 | 4903 | \end{itemdecl} |
4933 | 4904 |
|
4934 | 4905 | \begin{itemdescr} |
|
4959 | 4930 |
|
4960 | 4931 | \begin{itemdescr} |
4961 | 4932 | \pnum |
4962 | | -\requires |
4963 | | -\tcode{cat} shall be a catalog obtained from |
| 4933 | +\expects |
| 4934 | +\tcode{cat} is a catalog obtained from |
4964 | 4935 | \tcode{open()} |
4965 | 4936 | and not yet closed. |
4966 | 4937 |
|
|
4978 | 4949 |
|
4979 | 4950 | \begin{itemdescr} |
4980 | 4951 | \pnum |
4981 | | -\requires |
4982 | | -\tcode{cat} shall be a catalog obtained from |
| 4952 | +\expects |
| 4953 | +\tcode{cat} is a catalog obtained from |
4983 | 4954 | \tcode{open()} |
4984 | 4955 | and not yet closed. |
4985 | 4956 |
|
|
0 commit comments