4 "https://www.open-std.org/jtc1/sc22/wg21/docs/lwg-defects.html">
7 <part xmlns="http://docbook.org/ns/docbook" version="5.0" xml:id="manual.intro" xreflabel="Introduction">
8 <?dbhtml filename="intro.html"?>
12 <indexterm><primary>Introduction</primary></indexterm>
15 <keyword>ISO C++</keyword>
16 <keyword>library</keyword>
21 <!-- Chapter 01 : Status -->
22 <chapter xml:id="manual.intro.status" xreflabel="Status"><info><title>Status</title></info>
23 <?dbhtml filename="status.html"?>
26 <!-- Section 01 : Implementation Status -->
27 <section xml:id="manual.intro.status.iso" xreflabel="Status"><info><title>Implementation Status</title></info>
30 <!-- Section 01.1 : Status C++ 1998 -->
31 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" parse="xml" href="status_cxx1998.xml">
34 <!-- Section 01.2 : Status C++ 2011 -->
35 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" parse="xml" href="status_cxx2011.xml">
38 <!-- Section 01.3 : Status C++ 2014 -->
39 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" parse="xml" href="status_cxx2014.xml">
42 <!-- Section 01.4 : Status C++ 2017 -->
43 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" parse="xml" href="status_cxx2017.xml">
46 <!-- Section 01.4 : Status C++ 2020 -->
47 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" parse="xml" href="status_cxx2020.xml">
50 <!-- Section 01.5 : Status C++ 2023 -->
51 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" parse="xml" href="status_cxx2023.xml">
54 <!-- Section 01.6 : Status C++ TR1 -->
55 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" parse="xml" href="status_cxxtr1.xml">
58 <!-- Section 01.7 : Status C++ TR24733 -->
59 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" parse="xml" href="status_cxxtr24733.xml">
62 <!-- Section 01.8 : Status C++ IS 29124 -->
63 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" parse="xml" href="status_cxxis29124.xml">
67 <!-- Section 02 : License -->
68 <section xml:id="manual.intro.status.license" xreflabel="License"><info><title>License</title></info>
69 <?dbhtml filename="license.html"?>
72 There are two licenses affecting GNU libstdc++: one for the code,
73 and one for the documentation.
77 There is a license section in the FAQ regarding common <link linkend="faq.license">questions</link>. If you have more
78 questions, ask the FSF or the <link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="https://gcc.gnu.org/lists.html">gcc mailing list</link>.
81 <section xml:id="manual.intro.status.license.gpl" xreflabel="License GPL"><info><title>The Code: GPL</title></info>
85 The source code is distributed under the <link linkend="appendix.gpl-3.0">GNU General Public License version 3</link>,
86 with the addition under section 7 of an exception described in
87 the <quote>GCC Runtime Library Exception, version 3.1</quote>
88 as follows (or see the file COPYING.RUNTIME):
91 <literallayout class="normal">
92 GCC RUNTIME LIBRARY EXCEPTION
94 Version 3.1, 31 March 2009
96 Copyright (C) 2009 <link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="https://www.fsf.org">Free Software Foundation, Inc.</link>
98 Everyone is permitted to copy and distribute verbatim copies of this
99 license document, but changing it is not allowed.
101 This GCC Runtime Library Exception ("Exception") is an additional
102 permission under section 7 of the GNU General Public License, version
103 3 ("GPLv3"). It applies to a given file (the "Runtime Library") that
104 bears a notice placed by the copyright holder of the file stating that
105 the file is governed by GPLv3 along with this Exception.
107 When you use GCC to compile a program, GCC may combine portions of
108 certain GCC header files and runtime libraries with the compiled
109 program. The purpose of this Exception is to allow compilation of
110 non-GPL (including proprietary) programs to use, in this way, the
111 header files and runtime libraries covered by this Exception.
115 A file is an "Independent Module" if it either requires the Runtime
116 Library for execution after a Compilation Process, or makes use of an
117 interface provided by the Runtime Library, but is not otherwise based
118 on the Runtime Library.
120 "GCC" means a version of the GNU Compiler Collection, with or without
121 modifications, governed by version 3 (or a specified later version) of
122 the GNU General Public License (GPL) with the option of using any
123 subsequent versions published by the FSF.
125 "GPL-compatible Software" is software whose conditions of propagation,
126 modification and use would permit combination with GCC in accord with
129 "Target Code" refers to output from any compiler for a real or virtual
130 target processor architecture, in executable form or suitable for
131 input to an assembler, loader, linker and/or execution
132 phase. Notwithstanding that, Target Code does not include data in any
133 format that is used as a compiler intermediate representation, or used
134 for producing a compiler intermediate representation.
136 The "Compilation Process" transforms code entirely represented in
137 non-intermediate languages designed for human-written code, and/or in
138 Java Virtual Machine byte code, into Target Code. Thus, for example,
139 use of source code generators and preprocessors need not be considered
140 part of the Compilation Process, since the Compilation Process can be
141 understood as starting with the output of the generators or
144 A Compilation Process is "Eligible" if it is done using GCC, alone or
145 with other GPL-compatible software, or if it is done without using any
146 work based on GCC. For example, using non-GPL-compatible Software to
147 optimize any GCC intermediate representations would not qualify as an
148 Eligible Compilation Process.
150 1. Grant of Additional Permission.
152 You have permission to propagate a work of Target Code formed by
153 combining the Runtime Library with Independent Modules, even if such
154 propagation would otherwise violate the terms of GPLv3, provided that
155 all Target Code was generated by Eligible Compilation Processes. You
156 may then convey such a combination under terms of your choice,
157 consistent with the licensing of the Independent Modules.
159 2. No Weakening of GCC Copyleft.
161 The availability of this Exception does not imply any general
162 presumption that third-party software is unaffected by the copyleft
163 requirements of the license of GCC.
167 Hopefully that text is self-explanatory. If it isn't, you need to speak
168 to your lawyer, or the Free Software Foundation.
172 <section xml:id="manual.intro.status.license.fdl" xreflabel="License FDL"><info><title>The Documentation: GPL, FDL</title></info>
176 The documentation shipped with the library and made available over
177 the web, excluding the pages generated from source comments, are
178 copyrighted by the Free Software Foundation, and placed under the
179 <link linkend="appendix.gfdl-1.3"> GNU Free Documentation
180 License version 1.3</link>. There are no Front-Cover Texts, no
181 Back-Cover Texts, and no Invariant Sections.
185 For documentation generated by doxygen or other automated tools
186 via processing source code comments and markup, the original source
187 code license applies to the generated files. Thus, the doxygen
188 documents are licensed <link linkend="appendix.gpl-3.0">GPL</link>.
192 If you plan on making copies of the documentation, please let us know.
193 We can probably offer suggestions.
199 <!-- Section 03 : Known Bugs -->
200 <section xml:id="manual.intro.status.bugs" xreflabel="Bugs"><info><title>Bugs</title></info>
201 <?dbhtml filename="bugs.html"?>
204 <section xml:id="manual.intro.status.bugs.impl" xreflabel="Bugs impl"><info><title>Implementation Bugs</title></info>
207 Information on known bugs, details on efforts to fix them, and
208 fixed bugs are all available as part of the <link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="https://gcc.gnu.org/bugs/">GCC bug tracking system</link>,
209 under the component <quote>libstdc++</quote>.
213 <section xml:id="manual.intro.status.bugs.iso" xreflabel="Bugs iso"><info><title>Standard Bugs</title></info>
216 Everybody's got issues. Even the C++ Standard Library.
219 The Library Working Group, or LWG, is the ISO subcommittee responsible
220 for making changes to the library. They periodically publish an
221 Issues List containing problems and possible solutions. As they reach
222 a consensus on proposed solutions, we often incorporate the solution.
225 Here are the issues which have resulted in code changes to the library.
226 The links are to the full version of the Issues List.
227 You can read the full version online
228 at the <link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="https://www.open-std.org/jtc1/sc22/wg21/">ISO C++
229 Committee homepage</link>.
232 If a DR is not listed here, we may simply not have gotten to
233 it yet; feel free to submit a patch. Search the
234 <filename class="directory">include</filename> and
235 <filename class="directory">src</filename>
236 directories for appearances of
237 <constant>_GLIBCXX_RESOLVE_LIB_DEFECTS</constant> for examples
238 of style. Note that we usually do not make changes to the
239 code until an issue has reached <link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="https://www.open-std.org/jtc1/sc22/wg21/docs/lwg-active.html#DR">DR</link> status.
243 <varlistentry xml:id="manual.bugs.dr5"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#5">5</link>:
244 <emphasis role="bold">string::compare specification questionable</emphasis>
246 <listitem><para>This should be two overloaded functions rather than a single function.
247 </para></listitem></varlistentry>
249 <varlistentry xml:id="manual.bugs.dr17"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#17">17</link>:
250 <emphasis role="bold">Bad bool parsing</emphasis>
252 <listitem><para>Apparently extracting Boolean values was messed up...
253 </para></listitem></varlistentry>
255 <varlistentry xml:id="manual.bugs.dr19"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#19">19</link>:
256 <emphasis role="bold">"Noconv" definition too vague</emphasis>
258 <listitem><para>If <code>codecvt::do_in</code> returns <code>noconv</code> there are
259 no changes to the values in <code>[to, to_limit)</code>.
260 </para></listitem></varlistentry>
262 <varlistentry xml:id="manual.bugs.dr22"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#22">22</link>:
263 <emphasis role="bold">Member open vs flags</emphasis>
265 <listitem><para>Re-opening a file stream does <emphasis>not</emphasis> clear the state flags.
266 </para></listitem></varlistentry>
268 <varlistentry xml:id="manual.bugs.dr23"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#23">23</link>:
269 <emphasis role="bold">Num_get overflow result</emphasis>
271 <listitem><para>Implement the proposed resolution.
272 </para></listitem></varlistentry>
274 <varlistentry xml:id="manual.bugs.dr25"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#25">25</link>:
275 <emphasis role="bold">String operator<< uses width() value wrong</emphasis>
277 <listitem><para>Padding issues.
278 </para></listitem></varlistentry>
280 <varlistentry xml:id="manual.bugs.dr48"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#48">48</link>:
281 <emphasis role="bold">Use of non-existent exception constructor</emphasis>
283 <listitem><para>An instance of <code>ios_base::failure</code> is constructed instead.
284 </para></listitem></varlistentry>
286 <varlistentry xml:id="manual.bugs.dr49"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#49">49</link>:
287 <emphasis role="bold">Underspecification of ios_base::sync_with_stdio</emphasis>
289 <listitem><para>The return type is the <emphasis>previous</emphasis> state of synchronization.
290 </para></listitem></varlistentry>
292 <varlistentry xml:id="manual.bugs.dr50"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#50">50</link>:
293 <emphasis role="bold">Copy constructor and assignment operator of ios_base</emphasis>
295 <listitem><para>These members functions are declared <code>private</code> and are
296 thus inaccessible. Specifying the correct semantics of
297 "copying stream state" was deemed too complicated.
298 </para></listitem></varlistentry>
300 <varlistentry xml:id="manual.bugs.dr60"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#60">60</link>:
301 <emphasis role="bold">What is a formatted input function?</emphasis>
303 <listitem><para>This DR made many widespread changes to <code>basic_istream</code>
304 and <code>basic_ostream</code> all of which have been implemented.
305 </para></listitem></varlistentry>
307 <varlistentry xml:id="manual.bugs.dr63"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#63">63</link>:
308 <emphasis role="bold">Exception-handling policy for unformatted output</emphasis>
310 <listitem><para>Make the policy consistent with that of formatted input, unformatted
311 input, and formatted output.
312 </para></listitem></varlistentry>
314 <varlistentry xml:id="manual.bugs.dr68"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#68">68</link>:
315 <emphasis role="bold">Extractors for char* should store null at end</emphasis>
317 <listitem><para>And they do now. An editing glitch in the last item in the list of
319 </para></listitem></varlistentry>
321 <varlistentry xml:id="manual.bugs.dr74"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#74">74</link>:
322 <emphasis role="bold">Garbled text for codecvt::do_max_length</emphasis>
324 <listitem><para>The text of the standard was gibberish. Typos gone rampant.
325 </para></listitem></varlistentry>
327 <varlistentry xml:id="manual.bugs.dr75"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#75">75</link>:
328 <emphasis role="bold">Contradiction in codecvt::length's argument types</emphasis>
330 <listitem><para>Change the first parameter to <code>stateT&</code> and implement
331 the new effects paragraph.
332 </para></listitem></varlistentry>
334 <varlistentry xml:id="manual.bugs.dr83"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#83">83</link>:
335 <emphasis role="bold">string::npos vs. string::max_size()</emphasis>
337 <listitem><para>Safety checks on the size of the string should test against
338 <code>max_size()</code> rather than <code>npos</code>.
339 </para></listitem></varlistentry>
341 <varlistentry xml:id="manual.bugs.dr90"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#90">90</link>:
342 <emphasis role="bold">Incorrect description of operator>> for strings</emphasis>
344 <listitem><para>The effect contain <code>isspace(c,getloc())</code> which must be
345 replaced by <code>isspace(c,is.getloc())</code>.
346 </para></listitem></varlistentry>
348 <varlistentry xml:id="manual.bugs.dr91"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#91">91</link>:
349 <emphasis role="bold">Description of operator>> and getline() for string<>
350 might cause endless loop</emphasis>
352 <listitem><para>They behave as a formatted input function and as an unformatted
353 input function, respectively (except that <code>getline</code> is
354 not required to set <code>gcount</code>).
355 </para></listitem></varlistentry>
357 <varlistentry xml:id="manual.bugs.dr103"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#103">103</link>:
358 <emphasis role="bold">set::iterator is required to be modifiable, but this allows
359 modification of keys.</emphasis>
361 <listitem><para>For associative containers where the value type is the same as
362 the key type, both <code>iterator</code> and <code>const_iterator
363 </code> are constant iterators.
364 </para></listitem></varlistentry>
366 <varlistentry xml:id="manual.bugs.dr109"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#109">109</link>:
367 <emphasis role="bold">Missing binders for non-const sequence elements</emphasis>
369 <listitem><para>The <code>binder1st</code> and <code>binder2nd</code> didn't have an
370 <code>operator()</code> taking a non-const parameter.
371 </para></listitem></varlistentry>
373 <varlistentry xml:id="manual.bugs.dr110"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#110">110</link>:
374 <emphasis role="bold">istreambuf_iterator::equal not const</emphasis>
376 <listitem><para>This was not a const member function. Note that the DR says to
377 replace the function with a const one; we have instead provided an
378 overloaded version with identical contents.
379 </para></listitem></varlistentry>
381 <varlistentry xml:id="manual.bugs.dr117"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#117">117</link>:
382 <emphasis role="bold">basic_ostream uses nonexistent num_put member functions</emphasis>
384 <listitem><para><code>num_put::put()</code> was overloaded on the wrong types.
385 </para></listitem></varlistentry>
387 <varlistentry xml:id="manual.bugs.dr118"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#118">118</link>:
388 <emphasis role="bold">basic_istream uses nonexistent num_get member functions</emphasis>
390 <listitem><para>Same as 117, but for <code>num_get::get()</code>.
391 </para></listitem></varlistentry>
393 <varlistentry xml:id="manual.bugs.dr129"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#129">129</link>:
394 <emphasis role="bold">Need error indication from seekp() and seekg()</emphasis>
396 <listitem><para>These functions set <code>failbit</code> on error now.
397 </para></listitem></varlistentry>
399 <varlistentry xml:id="manual.bugs.dr130"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#130">130</link>:
400 <emphasis role="bold">Return type of container::erase(iterator) differs for associative containers</emphasis>
402 <listitem><para>Make member <code>erase</code> return iterator for <code>set</code>, <code>multiset</code>, <code>map</code>, <code>multimap</code>.
403 </para></listitem></varlistentry>
405 <varlistentry xml:id="manual.bugs.dr136"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#136">136</link>:
406 <emphasis role="bold">seekp, seekg setting wrong streams?</emphasis>
408 <listitem><para><code>seekp</code> should only set the output stream, and
409 <code>seekg</code> should only set the input stream.
410 </para></listitem></varlistentry>
412 <varlistentry xml:id="manual.bugs.dr167"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#167">167</link>:
413 <emphasis role="bold">Improper use of traits_type::length()</emphasis>
415 <listitem><para><code>op<<</code> with a <code>const char*</code> was
416 calculating an incorrect number of characters to write.
417 </para></listitem></varlistentry>
419 <varlistentry xml:id="manual.bugs.dr169"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#169">169</link>:
420 <emphasis role="bold">Bad efficiency of overflow() mandated</emphasis>
422 <listitem><para>Grow efficiently the internal array object.
423 </para></listitem></varlistentry>
425 <varlistentry xml:id="manual.bugs.dr171"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#171">171</link>:
426 <emphasis role="bold">Strange seekpos() semantics due to joint position</emphasis>
428 <listitem><para>Quite complex to summarize...
429 </para></listitem></varlistentry>
431 <varlistentry xml:id="manual.bugs.dr181"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#181">181</link>:
432 <emphasis role="bold">make_pair() unintended behavior</emphasis>
434 <listitem><para>This function used to take its arguments as reference-to-const, now
435 it copies them (pass by value).
436 </para></listitem></varlistentry>
438 <varlistentry xml:id="manual.bugs.dr195"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#195">195</link>:
439 <emphasis role="bold">Should basic_istream::sentry's constructor ever set eofbit?</emphasis>
441 <listitem><para>Yes, it can, specifically if EOF is reached while skipping whitespace.
442 </para></listitem></varlistentry>
444 <varlistentry xml:id="manual.bugs.dr206"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#206">206</link>:
445 <emphasis role="bold"><code>operator new(size_t, nothrow)</code> may become
446 unlinked to ordinary <code>operator new</code> if ordinary
450 <listitem><para>The <code>nothrow</code> forms of new and delete were
451 changed to call the throwing forms, handling any exception by
452 catching it and returning a null pointer.
453 </para></listitem></varlistentry>
455 <varlistentry xml:id="manual.bugs.dr211"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#211">211</link>:
456 <emphasis role="bold">operator>>(istream&, string&) doesn't set failbit</emphasis>
458 <listitem><para>If nothing is extracted into the string, <code>op>></code> now
459 sets <code>failbit</code> (which can cause an exception, etc., etc.).
460 </para></listitem></varlistentry>
462 <varlistentry xml:id="manual.bugs.dr214"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#214">214</link>:
463 <emphasis role="bold">set::find() missing const overload</emphasis>
465 <listitem><para>Both <code>set</code> and <code>multiset</code> were missing
466 overloaded find, lower_bound, upper_bound, and equal_range functions
468 </para></listitem></varlistentry>
470 <varlistentry xml:id="manual.bugs.dr231"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#231">231</link>:
471 <emphasis role="bold">Precision in iostream?</emphasis>
473 <listitem><para>For conversion from a floating-point type, <code>str.precision()</code>
474 is specified in the conversion specification.
475 </para></listitem></varlistentry>
477 <varlistentry xml:id="manual.bugs.dr233"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#233">233</link>:
478 <emphasis role="bold">Insertion hints in associative containers</emphasis>
480 <listitem><para>Implement N1780, first check before then check after, insert as close
482 </para></listitem></varlistentry>
484 <varlistentry xml:id="manual.bugs.dr235"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#235">235</link>:
485 <emphasis role="bold">No specification of default ctor for reverse_iterator</emphasis>
487 <listitem><para>The declaration of <code>reverse_iterator</code> lists a default constructor.
488 However, no specification is given what this constructor should do.
489 </para></listitem></varlistentry>
491 <varlistentry xml:id="manual.bugs.dr241"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#241">241</link>:
492 <emphasis role="bold">Does unique_copy() require CopyConstructible and Assignable?</emphasis>
494 <listitem><para>Add a helper for forward_iterator/output_iterator, fix the existing
495 one for input_iterator/output_iterator to not rely on Assignability.
496 </para></listitem></varlistentry>
498 <varlistentry xml:id="manual.bugs.dr243"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#243">243</link>:
499 <emphasis role="bold">get and getline when sentry reports failure</emphasis>
501 <listitem><para>Store a null character only if the character array has a non-zero size.
502 </para></listitem></varlistentry>
504 <varlistentry xml:id="manual.bugs.dr251"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#251">251</link>:
505 <emphasis role="bold">basic_stringbuf missing allocator_type</emphasis>
507 <listitem><para>This nested typedef was originally not specified.
508 </para></listitem></varlistentry>
510 <varlistentry xml:id="manual.bugs.dr253"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#253">253</link>:
511 <emphasis role="bold">valarray helper functions are almost entirely useless</emphasis>
513 <listitem><para>Make the copy constructor and copy-assignment operator declarations
514 public in gslice_array, indirect_array, mask_array, slice_array; provide
516 </para></listitem></varlistentry>
518 <varlistentry xml:id="manual.bugs.dr265"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#265">265</link>:
519 <emphasis role="bold">std::pair::pair() effects overly restrictive</emphasis>
521 <listitem><para>The default ctor would build its members from copies of temporaries;
522 now it simply uses their respective default ctors.
523 </para></listitem></varlistentry>
525 <varlistentry xml:id="manual.bugs.dr266"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#266">266</link>:
526 <emphasis role="bold">bad_exception::~bad_exception() missing Effects clause</emphasis>
528 <listitem><para>The <code>bad_</code>* classes no longer have destructors (they
529 are trivial), since no description of them was ever given.
530 </para></listitem></varlistentry>
532 <varlistentry xml:id="manual.bugs.dr271"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#271">271</link>:
533 <emphasis role="bold">basic_iostream missing typedefs</emphasis>
535 <listitem><para>The typedefs it inherits from its base classes can't be used, since
536 (for example) <code>basic_iostream<T>::traits_type</code> is ambiguous.
537 </para></listitem></varlistentry>
539 <varlistentry xml:id="manual.bugs.dr275"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#275">275</link>:
540 <emphasis role="bold">Wrong type in num_get::get() overloads</emphasis>
542 <listitem><para>Similar to 118.
543 </para></listitem></varlistentry>
545 <varlistentry xml:id="manual.bugs.dr280"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#280">280</link>:
546 <emphasis role="bold">Comparison of reverse_iterator to const reverse_iterator</emphasis>
548 <listitem><para>Add global functions with two template parameters.
549 (NB: not added for now a templated assignment operator)
550 </para></listitem></varlistentry>
552 <varlistentry xml:id="manual.bugs.dr292"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#292">292</link>:
553 <emphasis role="bold">Effects of a.copyfmt (a)</emphasis>
555 <listitem><para>If <code>(this == &rhs)</code> do nothing.
556 </para></listitem></varlistentry>
558 <varlistentry xml:id="manual.bugs.dr300"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#300">300</link>:
559 <emphasis role="bold">List::merge() specification incomplete</emphasis>
561 <listitem><para>If <code>(this == &x)</code> do nothing.
562 </para></listitem></varlistentry>
564 <varlistentry xml:id="manual.bugs.dr303"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#303">303</link>:
565 <emphasis role="bold">Bitset input operator underspecified</emphasis>
567 <listitem><para>Basically, compare the input character to
568 <code>is.widen(0)</code> and <code>is.widen(1)</code>.
569 </para></listitem></varlistentry>
571 <varlistentry xml:id="manual.bugs.dr305"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#305">305</link>:
572 <emphasis role="bold">Default behavior of codecvt<wchar_t, char,
573 mbstate_t>::length()</emphasis>
575 <listitem><para>Do not specify what <code>codecvt<wchar_t, char,
576 mbstate_t>::do_length</code> must return.
577 </para></listitem></varlistentry>
579 <varlistentry xml:id="manual.bugs.dr328"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#328">328</link>:
580 <emphasis role="bold">Bad sprintf format modifier in
581 money_put<>::do_put()</emphasis>
583 <listitem><para>Change the format string to "%.0Lf".
584 </para></listitem></varlistentry>
586 <varlistentry xml:id="manual.bugs.dr365"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#365">365</link>:
587 <emphasis role="bold">Lack of const-qualification in clause 27</emphasis>
589 <listitem><para>Add const overloads of <code>is_open</code>.
590 </para></listitem></varlistentry>
592 <varlistentry xml:id="manual.bugs.dr387"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#387">387</link>:
593 <emphasis role="bold">std::complex over-encapsulated</emphasis>
595 <listitem><para>Add the <code>real(T)</code> and <code>imag(T)</code>
596 members; in C++11 mode, also adjust the existing
597 <code>real()</code> and <code>imag()</code> members and
599 </para></listitem></varlistentry>
601 <varlistentry xml:id="manual.bugs.dr389"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#389">389</link>:
602 <emphasis role="bold">Const overload of valarray::operator[] returns
605 <listitem><para>Change it to return a <code>const T&</code>.
606 </para></listitem></varlistentry>
608 <varlistentry xml:id="manual.bugs.dr396"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#396">396</link>:
609 <emphasis role="bold">what are characters zero and one</emphasis>
611 <listitem><para>Implement the proposed resolution.
612 </para></listitem></varlistentry>
614 <varlistentry xml:id="manual.bugs.dr402"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#402">402</link>:
615 <emphasis role="bold">Wrong new expression in [some_]allocator::construct</emphasis>
617 <listitem><para>Replace "new" with "::new".
618 </para></listitem></varlistentry>
620 <varlistentry><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="../ext/lwg-closed.html#408">408</link>:
621 <emphasis role="bold">
622 Is vector<reverse_iterator<char*> > forbidden?
625 <listitem><para>Tweak the debug-mode checks in _Safe_iterator.
626 </para></listitem></varlistentry>
628 <varlistentry xml:id="manual.bugs.dr409"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#409">409</link>:
629 <emphasis role="bold">Closing an fstream should clear the error state</emphasis>
631 <listitem><para>Have <code>open</code> clear the error flags.
632 </para></listitem></varlistentry>
634 <varlistentry xml:id="manual.bugs.dr415"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#415">415</link>:
635 <emphasis role="bold">Behavior of std::ws</emphasis>
637 <listitem><para>Change it to be an unformatted input function
638 (i.e. construct a sentry and catch exceptions).
639 </para></listitem></varlistentry>
641 <varlistentry><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="../ext/lwg-closed.html#431">431</link>:
642 <emphasis role="bold">Swapping containers with unequal allocators</emphasis>
644 <listitem><para>Implement Option 3, as per N1599.
645 </para></listitem></varlistentry>
647 <varlistentry xml:id="manual.bugs.dr432"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#432">432</link>:
648 <emphasis role="bold">stringbuf::overflow() makes only one write position
651 <listitem><para>Implement the resolution, beyond DR 169.
652 </para></listitem></varlistentry>
654 <varlistentry xml:id="manual.bugs.dr434"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#434">434</link>:
655 <emphasis role="bold">bitset::to_string() hard to use</emphasis>
657 <listitem><para>Add three overloads, taking fewer template arguments.
658 </para></listitem></varlistentry>
660 <varlistentry xml:id="manual.bugs.dr438"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#438">438</link>:
661 <emphasis role="bold">Ambiguity in the "do the right thing" clause</emphasis>
663 <listitem><para>Implement the resolution, basically cast less.
664 </para></listitem></varlistentry>
666 <varlistentry xml:id="manual.bugs.dr445"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#445">445</link>:
667 <emphasis role="bold">iterator_traits::reference unspecified for some iterator categories</emphasis>
669 <listitem><para>Change <code>istreambuf_iterator::reference</code> in C++11 mode.
670 </para></listitem></varlistentry>
672 <varlistentry xml:id="manual.bugs.dr453"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#453">453</link>:
673 <emphasis role="bold">basic_stringbuf::seekoff need not always fail for an empty stream</emphasis>
675 <listitem><para>Don't fail if the next pointer is null and newoff is zero.
676 </para></listitem></varlistentry>
678 <varlistentry xml:id="manual.bugs.dr455"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#455">455</link>:
679 <emphasis role="bold">cerr::tie() and wcerr::tie() are overspecified</emphasis>
681 <listitem><para>Initialize cerr tied to cout and wcerr tied to wcout.
682 </para></listitem></varlistentry>
684 <varlistentry xml:id="manual.bugs.dr464"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#464">464</link>:
685 <emphasis role="bold">Suggestion for new member functions in standard containers</emphasis>
687 <listitem><para>Add <code>data()</code> to <code>std::vector</code> and
688 <code>at(const key_type&)</code> to <code>std::map</code>.
689 </para></listitem></varlistentry>
691 <varlistentry xml:id="manual.bugs.dr467"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#467">467</link>:
692 <emphasis role="bold">char_traits::lt(), compare(), and memcmp()</emphasis>
694 <listitem><para>Change <code>lt</code>.
695 </para></listitem></varlistentry>
697 <varlistentry xml:id="manual.bugs.dr508"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#508">508</link>:
698 <emphasis role="bold">Bad parameters for ranlux64_base_01</emphasis>
700 <listitem><para>Fix the parameters.
701 </para></listitem></varlistentry>
703 <varlistentry><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="../ext/lwg-closed.html#512">512</link>:
704 <emphasis role="bold">Seeding subtract_with_carry_01 from a single unsigned long</emphasis>
706 <listitem><para>Construct a <code>linear_congruential</code> engine and seed with it.
707 </para></listitem></varlistentry>
709 <varlistentry><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="../ext/lwg-closed.html#526">526</link>:
710 <emphasis role="bold">Is it undefined if a function in the standard changes in
711 parameters?</emphasis>
713 <listitem><para>Use &value.
714 </para></listitem></varlistentry>
716 <varlistentry xml:id="manual.bugs.dr538"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#538">538</link>:
717 <emphasis role="bold">241 again: Does unique_copy() require CopyConstructible
718 and Assignable?</emphasis>
720 <listitem><para>In case of input_iterator/output_iterator rely on Assignability of
721 input_iterator' value_type.
722 </para></listitem></varlistentry>
724 <varlistentry xml:id="manual.bugs.dr539"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#539">539</link>:
725 <emphasis role="bold">partial_sum and adjacent_difference should mention
726 requirements</emphasis>
728 <listitem><para>We were almost doing the right thing, just use std::move
729 in adjacent_difference.
730 </para></listitem></varlistentry>
732 <varlistentry xml:id="manual.bugs.dr541"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#541">541</link>:
733 <emphasis role="bold">shared_ptr template assignment and void</emphasis>
735 <listitem><para>Add an auto_ptr<void> specialization.
736 </para></listitem></varlistentry>
738 <varlistentry xml:id="manual.bugs.dr543"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#543">543</link>:
739 <emphasis role="bold">valarray slice default constructor</emphasis>
741 <listitem><para>Follow the straightforward proposed resolution.
742 </para></listitem></varlistentry>
744 <varlistentry xml:id="manual.bugs.dr550"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#550">550</link>:
745 <emphasis role="bold">What should the return type of pow(float,int) be?</emphasis>
747 <listitem><para>In C++11 mode, remove the pow(float,int), etc., signatures.
748 </para></listitem></varlistentry>
750 <varlistentry xml:id="manual.bugs.dr581"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#581">581</link>:
751 <emphasis role="bold"><code>flush()</code> not unformatted function</emphasis>
753 <listitem><para>Change it to be a unformatted output function (i.e. construct a sentry and catch exceptions).
754 </para></listitem></varlistentry>
756 <varlistentry xml:id="manual.bugs.dr586"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#586">586</link>:
757 <emphasis role="bold">string inserter not a formatted function</emphasis>
759 <listitem><para>Change it to be a formatted output function (i.e. catch exceptions).
760 </para></listitem></varlistentry>
762 <varlistentry xml:id="manual.bugs.dr596"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#596">596</link>:
763 <emphasis role="bold">27.8.1.3 Table 112 omits "a+" and "a+b" modes</emphasis>
765 <listitem><para>Add the missing modes to fopen_mode.
766 </para></listitem></varlistentry>
768 <varlistentry xml:id="manual.bugs.dr630"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#630">630</link>:
769 <emphasis role="bold">arrays of valarray</emphasis>
771 <listitem><para>Implement the simple resolution.
772 </para></listitem></varlistentry>
774 <varlistentry xml:id="manual.bugs.dr660"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#660">660</link>:
775 <emphasis role="bold">Missing bitwise operations</emphasis>
777 <listitem><para>Add the missing operations.
778 </para></listitem></varlistentry>
780 <varlistentry xml:id="manual.bugs.dr691"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#691">691</link>:
781 <emphasis role="bold">const_local_iterator cbegin, cend missing from TR1</emphasis>
783 <listitem><para>In C++11 mode add cbegin(size_type) and cend(size_type)
784 to the unordered containers.
785 </para></listitem></varlistentry>
787 <varlistentry xml:id="manual.bugs.dr693"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#693">693</link>:
788 <emphasis role="bold">std::bitset::all() missing</emphasis>
790 <listitem><para>Add it, consistently with the discussion.
791 </para></listitem></varlistentry>
793 <varlistentry xml:id="manual.bugs.dr695"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#695">695</link>:
794 <emphasis role="bold">ctype<char>::classic_table() not accessible</emphasis>
796 <listitem><para>Make the member functions table and classic_table public.
797 </para></listitem></varlistentry>
799 <varlistentry xml:id="manual.bugs.dr696"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#696">696</link>:
800 <emphasis role="bold">istream::operator>>(int&) broken</emphasis>
802 <listitem><para>Implement the straightforward resolution.
803 </para></listitem></varlistentry>
805 <varlistentry xml:id="manual.bugs.dr761"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#761">761</link>:
806 <emphasis role="bold">unordered_map needs an at() member function</emphasis>
808 <listitem><para>In C++11 mode, add at() and at() const.
809 </para></listitem></varlistentry>
811 <varlistentry xml:id="manual.bugs.dr775"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#775">775</link>:
812 <emphasis role="bold">Tuple indexing should be unsigned?</emphasis>
814 <listitem><para>Implement the int -> size_t replacements.
815 </para></listitem></varlistentry>
817 <varlistentry xml:id="manual.bugs.dr776"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#776">776</link>:
818 <emphasis role="bold">Undescribed assign function of std::array</emphasis>
820 <listitem><para>In C++11 mode, remove assign, add fill.
821 </para></listitem></varlistentry>
823 <varlistentry xml:id="manual.bugs.dr781"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#781">781</link>:
824 <emphasis role="bold">std::complex should add missing C99 functions</emphasis>
826 <listitem><para>In C++11 mode, add std::proj.
827 </para></listitem></varlistentry>
829 <varlistentry xml:id="manual.bugs.dr809"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#809">809</link>:
830 <emphasis role="bold">std::swap should be overloaded for array types</emphasis>
832 <listitem><para>Add the overload.
833 </para></listitem></varlistentry>
835 <varlistentry xml:id="manual.bugs.dr853"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#853">853</link>:
836 <emphasis role="bold">to_string needs updating with zero and one</emphasis>
838 <listitem><para>Update / add the signatures.
839 </para></listitem></varlistentry>
841 <varlistentry xml:id="manual.bugs.dr865"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#865">865</link>:
842 <emphasis role="bold">More algorithms that throw away information</emphasis>
844 <listitem><para>The traditional HP / SGI return type and value is blessed
845 by the resolution of the DR.
846 </para></listitem></varlistentry>
848 <varlistentry xml:id="manual.bugs.dr1203"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#1203">1203</link>:
849 <emphasis role="bold">More useful rvalue stream insertion</emphasis>
851 <listitem><para>Return the stream as its original type, not the base class.
852 </para></listitem></varlistentry>
854 <varlistentry xml:id="manual.bugs.dr1339"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#1339">1339</link>:
855 <emphasis role="bold">uninitialized_fill_n should return the end of its range</emphasis>
857 <listitem><para>Return the end of the filled range.
858 </para></listitem></varlistentry>
860 <varlistentry xml:id="manual.bugs.dr2021"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2021">2021</link>:
861 <emphasis role="bold">Further incorrect uses of <code>result_of</code></emphasis>
863 <listitem><para>Correctly decay types in signature of <code>std::async</code>.
864 </para></listitem></varlistentry>
866 <varlistentry xml:id="manual.bugs.dr2049"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2049">2049</link>:
867 <emphasis role="bold"><code>is_destructible</code> underspecified</emphasis>
869 <listitem><para>Handle non-object types.
870 </para></listitem></varlistentry>
872 <varlistentry xml:id="manual.bugs.dr2056"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2056">2056</link>:
873 <emphasis role="bold">future_errc enums start with value 0 (invalid value for broken_promise)</emphasis>
875 <listitem><para>Reorder enumerators.
876 </para></listitem></varlistentry>
878 <varlistentry xml:id="manual.bugs.dr2059"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2059">2059</link>:
879 <emphasis role="bold">C++0x ambiguity problem with map::erase</emphasis>
881 <listitem><para>Add additional overloads.
882 </para></listitem></varlistentry>
884 <varlistentry xml:id="manual.bugs.dr2062"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2062">2062</link>:
885 <emphasis role="bold">2062. Effect contradictions w/o no-throw guarantee of <code>std::function</code> swaps</emphasis>
887 <listitem><para>Add <code>noexcept</code> to swap functions.
888 </para></listitem></varlistentry>
890 <varlistentry xml:id="manual.bugs.dr2063"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2063">2063</link>:
891 <emphasis role="bold">Contradictory requirements for string move assignment</emphasis>
893 <listitem><para>Respect propagation trait for move assignment.
894 </para></listitem></varlistentry>
896 <varlistentry xml:id="manual.bugs.dr2064"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2064">2064</link>:
897 <emphasis role="bold">More noexcept issues in basic_string</emphasis>
899 <listitem><para>Add noexcept to the comparison operators.
900 </para></listitem></varlistentry>
902 <varlistentry xml:id="manual.bugs.dr2067"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2067">2067</link>:
903 <emphasis role="bold">packaged_task should have deleted copy c'tor with const parameter</emphasis>
905 <listitem><para>Fix signatures.
906 </para></listitem></varlistentry>
908 <varlistentry xml:id="manual.bugs.dr2101"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2101">2101</link>:
909 <emphasis role="bold">Some transformation types can produce impossible types</emphasis>
911 <listitem><para>Use the referenceable type concept.
912 </para></listitem></varlistentry>
914 <varlistentry xml:id="manual.bugs.dr2106"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2106">2106</link>:
915 <emphasis role="bold">move_iterator wrapping iterators returning prvalues</emphasis>
917 <listitem><para>Change the <code>reference</code> type.
918 </para></listitem></varlistentry>
920 <varlistentry xml:id="manual.bugs.dr2108"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2108">2108</link>:
921 <emphasis role="bold">No way to identify allocator types that always compare equal</emphasis>
923 <listitem><para>Define and use <code>is_always_equal</code> even for C++11.
924 </para></listitem></varlistentry>
926 <varlistentry xml:id="manual.bugs.dr2118"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2118">2118</link>:
927 <emphasis role="bold"><code>unique_ptr</code> for array does not support cv qualification conversion of actual argument</emphasis>
929 <listitem><para>Adjust constraints to allow safe conversions.
930 </para></listitem></varlistentry>
932 <varlistentry xml:id="manual.bugs.dr2127"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2127">2127</link>:
933 <emphasis role="bold">Move-construction with <code>raw_storage_iterator</code></emphasis>
935 <listitem><para>Add assignment operator taking an rvalue.
936 </para></listitem></varlistentry>
938 <varlistentry xml:id="manual.bugs.dr2132"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2132">2132</link>:
939 <emphasis role="bold"><code>std::function</code> ambiguity</emphasis>
941 <listitem><para>Constrain the constructor to only accept callable types.
942 </para></listitem></varlistentry>
944 <varlistentry xml:id="manual.bugs.dr2141"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2141">2141</link>:
945 <emphasis role="bold"><code>common_type</code> trait produces reference types</emphasis>
947 <listitem><para>Use <code>decay</code> for the result type.
948 </para></listitem></varlistentry>
950 <varlistentry xml:id="manual.bugs.dr2144"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2144">2144</link>:
951 <emphasis role="bold">Missing <code>noexcept</code> specification in <code>type_index</code></emphasis>
953 <listitem><para>Add <code>noexcept</code>
954 </para></listitem></varlistentry>
956 <varlistentry xml:id="manual.bugs.dr2145"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2145">2145</link>:
957 <emphasis role="bold"><code>error_category</code> default constructor</emphasis>
959 <listitem><para>Declare a public constexpr constructor.
960 </para></listitem></varlistentry>
962 <varlistentry xml:id="manual.bugs.dr2162"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2162">2162</link>:
963 <emphasis role="bold"><code>allocator_traits::max_size</code> missing <code>noexcept</code></emphasis>
965 <listitem><para>Add <code>noexcept</code>.
966 </para></listitem></varlistentry>
968 <varlistentry xml:id="manual.bugs.dr2187"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2187">2187</link>:
969 <emphasis role="bold"><code>vector<bool></code> is missing <code>emplace</code> and <code>emplace_back</code> member functions</emphasis>
971 <listitem><para>Add <code>emplace</code> and <code>emplace_back</code> member functions.
972 </para></listitem></varlistentry>
974 <varlistentry xml:id="manual.bugs.dr2192"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2192">2192</link>:
975 <emphasis role="bold">Validity and return type of <code>std::abs(0u)</code> is unclear</emphasis>
977 <listitem><para>Move all declarations to a common header and remove the
978 generic <code>abs</code> which accepted unsigned arguments.
979 </para></listitem></varlistentry>
981 <varlistentry xml:id="manual.bugs.dr2196"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2196">2196</link>:
982 <emphasis role="bold">Specification of <code>is_*[copy/move]_[constructible/assignable]</code> unclear for non-referencable types</emphasis>
984 <listitem><para>Use the referenceable type concept.
985 </para></listitem></varlistentry>
987 <varlistentry xml:id="manual.bugs.dr2212"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2212">2212</link>:
988 <emphasis role="bold"><code>tuple_size</code> for <code>const pair</code> request <code><tuple></code> header</emphasis>
990 <listitem><para>The <code>tuple_size</code> and <code>tuple_element</code>
991 partial specializations are defined in <code><utility></code> which
992 is included by <code><array></code>.
993 </para></listitem></varlistentry>
995 <varlistentry xml:id="manual.bugs.dr2296"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2296">2296</link>:
996 <emphasis role="bold"><code>std::addressof</code> should be constexpr</emphasis>
998 <listitem><para>Use <code>__builtin_addressof</code> and add
999 <code>constexpr</code> to <code>addressof</code> for C++17 and later.
1000 </para></listitem></varlistentry>
1002 <varlistentry xml:id="manual.bugs.dr2306"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2306">2306</link>:
1003 <emphasis role="bold"><code>match_results::reference</code> should be <code>value_type&</code>, not <code>const value_type&</code></emphasis>
1005 <listitem><para>Change typedef.
1006 </para></listitem></varlistentry>
1008 <varlistentry xml:id="manual.bugs.dr2313"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2313">2313</link>:
1009 <emphasis role="bold"><code>tuple_size</code> should always derive from <code>integral_constant<size_t, N></code></emphasis>
1011 <listitem><para>Update definitions of the partial specializations for const and volatile types.
1012 </para></listitem></varlistentry>
1014 <varlistentry xml:id="manual.bugs.dr2328"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2328">2328</link>:
1015 <emphasis role="bold">Rvalue stream extraction should use perfect forwarding</emphasis>
1017 <listitem><para>Use perfect forwarding for right operand.
1018 </para></listitem></varlistentry>
1020 <varlistentry xml:id="manual.bugs.dr2329"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2329">2329</link>:
1021 <emphasis role="bold"><code>regex_match()/regex_search()</code> with <code>match_results</code> should forbid temporary strings</emphasis>
1023 <listitem><para>Add deleted overloads for rvalue strings.
1024 </para></listitem></varlistentry>
1026 <varlistentry xml:id="manual.bugs.dr2332"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2332">2332</link>:
1027 <emphasis role="bold"><code>regex_iterator/regex_token_iterator</code> should forbid temporary regexes</emphasis>
1029 <listitem><para>Add deleted constructors.
1030 </para></listitem></varlistentry>
1032 <varlistentry xml:id="manual.bugs.dr2354"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2354">2332</link>:
1033 <emphasis role="bold">Unnecessary copying when inserting into maps with braced-init syntax</emphasis>
1035 <listitem><para>Add overloads of <code>insert</code> taking <code>value_type&&</code> rvalues.
1036 </para></listitem></varlistentry>
1038 <varlistentry xml:id="manual.bugs.dr2399"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2399">2399</link>:
1039 <emphasis role="bold"><code>shared_ptr</code>'s constructor from <code>unique_ptr</code> should be constrained</emphasis>
1041 <listitem><para>Constrain the constructor to require convertibility.
1042 </para></listitem></varlistentry>
1044 <varlistentry xml:id="manual.bugs.dr2400"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2400">2400</link>:
1045 <emphasis role="bold"><code>shared_ptr</code>'s <code>get_deleter()</code> should use <code>addressof()</code></emphasis>
1047 <listitem><para>Use <code>addressof</code>.
1048 </para></listitem></varlistentry>
1050 <varlistentry xml:id="manual.bugs.dr2401"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2401">2401</link>:
1051 <emphasis role="bold"><code>std::function</code> needs more <code>noexcept</code></emphasis>
1053 <listitem><para>Add <code>noexcept</code> to the assignment and comparisons.
1054 </para></listitem></varlistentry>
1056 <varlistentry xml:id="manual.bugs.dr2407"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2407">2407</link>:
1057 <emphasis role="bold"><code>packaged_task(allocator_arg_t, const Allocator&, F&&)</code>
1058 should neither be constrained nor <code>explicit</code>
1061 <listitem><para>Remove <code>explicit</code> from the constructor.
1062 </para></listitem></varlistentry>
1064 <varlistentry xml:id="manual.bugs.dr2408"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2408">2408</link>:
1065 <emphasis role="bold">SFINAE-friendly
1066 <code>common_type</code>/<code>iterator_traits</code>
1070 <listitem><para>Make <code>iterator_traits</code> empty if any of the
1071 types is not present in the iterator.
1072 Make <code>common_type<></code> empty.
1073 </para></listitem></varlistentry>
1075 <varlistentry xml:id="manual.bugs.dr2415"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2415">2415</link>:
1076 <emphasis role="bold">Inconsistency between <code>unique_ptr</code> and <code>shared_ptr</code></emphasis>
1078 <listitem><para>Create empty an <code>shared_ptr</code> from an empty
1079 <code>unique_ptr</code>.
1080 </para></listitem></varlistentry>
1082 <varlistentry xml:id="manual.bugs.dr2418"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2418">2418</link>:
1083 <emphasis role="bold"><code>apply</code> does not work with member pointers</emphasis>
1085 <listitem><para>Use <code>mem_fn</code> for member pointers.
1086 </para></listitem></varlistentry>
1088 <varlistentry xml:id="manual.bugs.dr2440"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2440">2440</link>:
1089 <emphasis role="bold"><code>seed_seq::size()</code> should be <code>noexcept</code></emphasis>
1091 <listitem><para>Add <code>noexcept</code>.
1092 </para></listitem></varlistentry>
1094 <varlistentry xml:id="manual.bugs.dr2441"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2441">2441</link>:
1095 <emphasis role="bold">Exact-width atomic typedefs should be provided</emphasis>
1097 <listitem><para>Define the typedefs.
1098 </para></listitem></varlistentry>
1100 <varlistentry xml:id="manual.bugs.dr2442"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2442">2442</link>:
1101 <emphasis role="bold"><code>call_once()</code> shouldn't <code>DECAY_COPY()</code></emphasis>
1103 <listitem><para>Remove indirection through call wrapper that made copies
1104 of arguments and forward arguments straight to <code>std::invoke</code>.
1105 </para></listitem></varlistentry>
1107 <varlistentry xml:id="manual.bugs.dr2454"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2454">2454</link>:
1108 <emphasis role="bold">Add <code>raw_storage_iterator::base()</code> member
1111 <listitem><para>Add the <code>base()</code> member function.
1112 </para></listitem></varlistentry>
1114 <varlistentry xml:id="manual.bugs.dr2455"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2455">2455</link>:
1115 <emphasis role="bold">Allocator default construction should be allowed to throw
1118 <listitem><para>Make <code>noexcept</code> specifications conditional.
1119 </para></listitem></varlistentry>
1121 <varlistentry xml:id="manual.bugs.dr2458"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2458">2458</link>:
1122 <emphasis role="bold">N3778 and new library deallocation signatures
1125 <listitem><para>Remove unused overloads.
1126 </para></listitem></varlistentry>
1128 <varlistentry xml:id="manual.bugs.dr2459"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2459">2459</link>:
1129 <emphasis role="bold"><code>std::polar</code> should require a non-negative rho
1132 <listitem><para>Add debug mode assertion.
1133 </para></listitem></varlistentry>
1135 <varlistentry xml:id="manual.bugs.dr2465"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2465">2465</link>:
1136 <emphasis role="bold">SFINAE-friendly <code>common_type</code> is nearly impossible
1137 to specialize correctly and regresses key functionality
1140 <listitem><para>Detect whether <code>decay_t</code> changes either type
1141 and use the decayed types if so.
1142 </para></listitem></varlistentry>
1144 <varlistentry xml:id="manual.bugs.dr2466"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2466">2466</link>:
1145 <emphasis role="bold"><code>allocator_traits::max_size()</code> default behavior is incorrect
1148 <listitem><para>Divide by the object type.
1149 </para></listitem></varlistentry>
1151 <varlistentry xml:id="manual.bugs.dr2484"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2484">2484</link>:
1152 <emphasis role="bold"><code>rethrow_if_nested()</code> is doubly unimplementable
1155 <listitem><para>Avoid using <code>dynamic_cast</code> when it would be
1157 </para></listitem></varlistentry>
1159 <varlistentry xml:id="manual.bugs.dr2487"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2487">2487</link>:
1160 <emphasis role="bold"><code>bind()</code> should be <code>const</code>-overloaded
1161 not <emphasis>cv</emphasis>-overloaded
1164 <listitem><para>Deprecate volatile-qualified <code>operator()</code>
1165 for C++17, make it ill-formed for C++20.
1166 </para></listitem></varlistentry>
1168 <varlistentry xml:id="manual.bugs.dr2499"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2499">2499</link>:
1169 <emphasis role="bold"><code>operator>>(basic_istream&, CharT*)</code> makes it hard to avoid buffer overflows
1172 <listitem><para>Replace <code>operator>>(basic_istream&, CharT*)</code>
1173 and other overloads writing through pointers.
1174 </para></listitem></varlistentry>
1176 <varlistentry xml:id="manual.bugs.dr2537"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2537">2537</link>:
1177 <emphasis role="bold">Constructors for <code>priority_queue</code> taking allocators
1178 should call <code>make_heap</code>
1181 <listitem><para>Call <code>make_heap</code>.
1182 </para></listitem></varlistentry>
1184 <varlistentry xml:id="manual.bugs.dr2566"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2566">2566</link>:
1185 <emphasis role="bold">Requirements on the first template parameter of container adaptors
1188 <listitem><para>Add static assertions to enforce the requirement.
1189 </para></listitem></varlistentry>
1191 <varlistentry xml:id="manual.bugs.dr2583"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2583">2583</link>:
1192 <emphasis role="bold">There is no way to supply an allocator for <code>basic_string(str, pos)</code>
1195 <listitem><para>Add new constructor.
1196 </para></listitem></varlistentry>
1198 <varlistentry xml:id="manual.bugs.dr2586"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2586">2586</link>:
1199 <emphasis role="bold">Wrong value category used in <code>scoped_allocator_adaptor::construct()</code>
1202 <listitem><para>Change internal helper for uses-allocator construction
1203 to always check using const lvalue allocators.
1204 </para></listitem></varlistentry>
1206 <varlistentry xml:id="manual.bugs.dr2684"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2684">2684</link>:
1207 <emphasis role="bold"><code>priority_queue</code> lacking comparator typedef
1210 <listitem><para>Define the <code>value_compare</code> typedef.
1211 </para></listitem></varlistentry>
1213 <varlistentry xml:id="manual.bugs.dr2735"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2735">2735</link>:
1214 <emphasis role="bold"><code>std::abs(short)</code>,
1215 <code>std::abs(signed char)</code> and others should return
1216 <code>int</code> instead of <code>double</code> in order to be
1217 compatible with C++98 and C
1220 <listitem><para>Resolved by the changes for
1221 <link linkend="manual.bugs.dr2192">2192</link>.
1222 </para></listitem></varlistentry>
1224 <varlistentry xml:id="manual.bugs.dr2770"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2770">2770</link>:
1225 <emphasis role="bold"><code>tuple_size<const T></code> specialization is not
1226 SFINAE compatible and breaks decomposition declarations
1229 <listitem><para>Safely detect <code>tuple_size<T>::value</code> and
1230 only use it if valid.
1231 </para></listitem></varlistentry>
1233 <varlistentry xml:id="manual.bugs.dr2781"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2781">2781</link>:
1234 <emphasis role="bold">Contradictory requirements for <code>std::function</code>
1235 and <code>std::reference_wrapper</code>
1238 <listitem><para>Remove special handling for <code>reference_wrapper</code>
1239 arguments and store them directly as the target object.
1240 </para></listitem></varlistentry>
1242 <varlistentry xml:id="manual.bugs.dr2802"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2802">2802</link>:
1243 <emphasis role="bold">Add noexcept to several <code>shared_ptr</code> related
1247 <listitem><para>Add noexcept.
1248 </para></listitem></varlistentry>
1250 <varlistentry xml:id="manual.bugs.dr2873"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2873">2873</link>:
1251 <emphasis role="bold"><code>shared_ptr</code> constructor requirements for a deleter
1254 <listitem><para>Use rvalues for deleters.
1255 </para></listitem></varlistentry>
1257 <varlistentry xml:id="manual.bugs.dr2921"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2921">2921</link>:
1258 <emphasis role="bold"><code>packaged_task</code> and type-erased allocators
1261 <listitem><para>For C++17 mode, remove the constructors taking
1262 an allocator argument.
1263 </para></listitem></varlistentry>
1265 <varlistentry xml:id="manual.bugs.dr2942"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2942">2942</link>:
1266 <emphasis role="bold">LWG 2873's resolution missed
1267 <code>weak_ptr::owner_before</code>
1270 <listitem><para>Add noexcept.
1271 </para></listitem></varlistentry>
1273 <varlistentry xml:id="manual.bugs.dr2996"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2996">2996</link>:
1274 <emphasis role="bold">Missing rvalue overloads for
1275 <code>shared_ptr</code> operations
1278 <listitem><para>Add additional constructor and cast overloads.
1279 </para></listitem></varlistentry>
1281 <varlistentry xml:id="manual.bugs.dr2993"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2993">2993</link>:
1282 <emphasis role="bold"><code>reference_wrapper<T></code> conversion from <code>T&&</code>
1285 <listitem><para>Replaced the constructors with a constrained template,
1286 to prevent participation in overload resolution when not valid.
1287 </para></listitem></varlistentry>
1289 <varlistentry xml:id="manual.bugs.dr3074"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#3074">3074</link>:
1290 <emphasis role="bold">Non-member functions for <code>valarray</code> should only deduce from the <code>valarray</code>
1293 <listitem><para>Change scalar operands to be non-deduced context, so that
1294 they will allow conversions from other types to the value_type.
1295 </para></listitem></varlistentry>
1297 <varlistentry xml:id="manual.bugs.dr3076"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#3076">3076</link>:
1298 <emphasis role="bold"><code>basic_string</code> CTAD ambiguity
1301 <listitem><para>Change constructors to constrained templates.
1302 </para></listitem></varlistentry>
1304 <varlistentry xml:id="manual.bugs.dr3096"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#3096">3096</link>:
1305 <emphasis role="bold"><code>path::lexically_relative</code> is confused by trailing slashes
1308 <listitem><para>Implement the fix for trailing slashes.
1309 </para></listitem></varlistentry>
1311 <varlistentry xml:id="manual.bugs.dr3656"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#3656">3656</link>:
1312 <emphasis role="bold">Inconsistent bit operations returning a count
1315 <listitem><para>Changed <code>bit_width</code> to return <code>int</code>.
1316 </para></listitem></varlistentry>
1325 <!-- Chapter 02 : Setup -->
1326 <chapter xml:id="manual.intro.setup" xreflabel="Setup"><info><title>Setup</title></info>
1327 <?dbhtml filename="setup.html"?>
1330 <para>Transforming libstdc++ sources into installed include files
1331 and properly built binaries useful for linking to other software is
1332 done as part of building GCC. Building libstdc++ separately from the
1333 rest of GCC is not supported.
1336 <para>The general outline of commands to build GCC is something like:
1340 <replaceable>get gcc sources</replaceable>
1341 <replaceable>extract into gccsrcdir</replaceable>
1342 mkdir <replaceable>gccbuilddir</replaceable>
1343 cd <replaceable>gccbuilddir</replaceable>
1344 <replaceable>gccsrcdir</replaceable>/configure --prefix=<replaceable>destdir</replaceable> --other-opts...
1351 Each step is described in more detail in the following sections.
1354 <!-- Section 01 : Prerequisites -->
1355 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" parse="xml" href="prerequisites.xml">
1358 <!-- Section 02 : Configure -->
1359 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" parse="xml" href="configure.xml">
1362 <!-- Section 03 : Make -->
1363 <section xml:id="manual.intro.setup.make" xreflabel="Make"><info><title>Make</title></info>
1364 <?dbhtml filename="make.html"?>
1366 <para>If you have never done this before, you should read the basic
1367 <link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="https://gcc.gnu.org/install/">GCC Installation
1368 Instructions</link> first. Read <emphasis>all of them</emphasis>.
1369 <emphasis>Twice.</emphasis>
1372 <para>Then type: <command>make</command>, and congratulations, you've
1380 <!-- Chapter 03 : Using -->
1381 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" parse="xml" href="using.xml">