1<book xmlns="http://docbook.org/ns/docbook" version="5.0">
2
3<article xml:id="faq" xreflabel="Frequently Asked Questions">
4<?dbhtml filename="faq.html"?>
5
6<info><title>Frequently Asked Questions</title>
7
8  <copyright>
9    <year>
10      2008-2014
11    </year>
12    <holder>
13      <link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="http://www.fsf.org">FSF</link>
14    </holder>
15  </copyright>
16</info>
17
18<!-- FAQ starts here -->
19<qandaset xml:id="faq.faq">
20
21<!-- General Information -->
22<qandadiv xml:id="faq.info" xreflabel="General Information">
23
24<qandaentry xml:id="faq.what">
25  <question xml:id="faq.what.q">
26    <para>
27      What is libstdc++?
28    </para>
29  </question>
30  <answer xml:id="faq.what.a">
31    <para>
32     The GNU Standard C++ Library v3 is an ongoing project to
33     implement the ISO 14882 Standard C++ library as described in
34     clauses 17 through 30 and annex D.  For those who want to see
35     exactly how far the project has come, or just want the latest
36     bleeding-edge code, the up-to-date source is available over
37     anonymous SVN, and can be browsed over
38     the <link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="https://gcc.gnu.org/svn.html">web</link>.
39    </para>
40  </answer>
41</qandaentry>
42
43<qandaentry xml:id="faq.why">
44  <question xml:id="q-why">
45    <para>
46      Why should I use libstdc++?
47    </para>
48  </question>
49  <answer xml:id="a-why">
50    <para>
51    The completion of the initial ISO C++ standardization effort gave the C++
52    community a powerful set of reuseable tools in the form of the C++
53    Standard Library.  However, for several years C++ implementations were
54    (as the Draft Standard used to say) <quote>incomplet and
55    incorrekt</quote>, and many suffered from limitations of the compilers
56    that used them.
57    </para>
58    <para>
59    The GNU compiler collection
60    (<command>gcc</command>, <command>g++</command>, etc) is widely
61    considered to be one of the leading compilers in the world.  Its
62    development is overseen by the
63    <link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="https://gcc.gnu.org/">GCC team</link>.  All of
64    the rapid development and near-legendary
65    <link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="https://gcc.gnu.org/buildstat.html">portability</link>
66    that are the hallmarks of an open-source project are applied to libstdc++.
67    </para>
68    <para>
69    All of the standard classes and functions from C++98/C++03
70    (such as <classname>string</classname>,
71    <classname>vector&lt;&gt;</classname>, iostreams, algorithms etc.)
72    are freely available and atempt to be fully compliant.
73    Work is ongoing to complete support for the current revision of the
74    ISO C++ Standard.
75    </para>
76  </answer>
77</qandaentry>
78
79<qandaentry xml:id="faq.who">
80  <question xml:id="q-who">
81    <para>
82      Who's in charge of it?
83    </para>
84  </question>
85  <answer xml:id="a-who">
86    <para>
87     The libstdc++ project is contributed to by several developers
88     all over the world, in the same way as GCC or the Linux kernel.
89     The current maintainers are listed in the
90     <link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="https://gcc.gnu.org/viewcvs/gcc/trunk/MAINTAINERS?view=co"><filename>MAINTAINERS</filename></link>
91     file (look for "c++ runtime libs").
92    </para>
93    <para>
94    Development and discussion is held on the libstdc++ mailing
95    list.  Subscribing to the list, or searching the list
96    archives, is open to everyone.  You can read instructions for
97    doing so on the <link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="https://gcc.gnu.org/lists.html">GCC mailing lists</link> page.
98    If you have questions, ideas, code, or are just curious, sign up!
99    </para>
100  </answer>
101</qandaentry>
102
103<qandaentry xml:id="faq.when">
104  <question xml:id="q-when">
105    <para>
106      When is libstdc++ going to be finished?
107    </para>
108  </question>
109  <answer xml:id="a-when">
110    <para>
111    Nathan Myers gave the best of all possible answers, responding to
112    a Usenet article asking this question: <emphasis>Sooner, if you
113    help.</emphasis>
114    </para>
115  </answer>
116</qandaentry>
117
118<qandaentry xml:id="faq.how">
119  <question xml:id="q-how">
120    <para>
121      How do I contribute to the effort?
122    </para>
123  </question>
124  <answer xml:id="a-how">
125    <para>
126    See the <link linkend="appendix.contrib">Contributing</link> section in
127    the manual. Subscribing to the mailing list (see above, or
128    the homepage) is a very good idea if you have something to
129    contribute, or if you have spare time and want to
130    help. Contributions don't have to be in the form of source code;
131    anybody who is willing to help write documentation, for example,
132    or has found a bug in code that we all thought was working and is
133    willing to provide details, is more than welcome!
134    </para>
135  </answer>
136</qandaentry>
137
138<qandaentry xml:id="faq.whereis_old">
139  <question xml:id="q-whereis_old">
140    <para>
141      What happened to the older libg++? I need that!
142    </para>
143  </question>
144  <answer xml:id="a-whereis_old">
145    <para>
146    The last libg++ README states
147    <quote>This package is considered obsolete and is no longer
148    being developed.</quote>
149    It should not be used for new projects, and won't even compile with
150    recent releases of GCC (or most other C++ compilers).
151    </para>
152    <para>
153    More information can be found in the
154    <link linkend="manual.appendix.porting.backwards">Backwards
155    Compatibility</link> section of the libstdc++ manual.
156    </para>
157  </answer>
158</qandaentry>
159
160<qandaentry xml:id="faq.more_questions">
161  <question xml:id="q-more_questions">
162    <para>
163      What if I have more questions?
164    </para>
165  </question>
166  <answer xml:id="a-more_questions">
167    <para>
168    If you have read the documentation, and your question remains
169    unanswered, then just ask the mailing list. At present, you do not
170    need to be subscribed to the list to send a message to it.  More
171    information is available on the homepage (including how to browse
172    the list archives); to send a message to the list,
173    use <email>libstdc++@gcc.gnu.org</email>.
174    </para>
175
176    <para>
177    If you have a question that you think should be included
178    here, or if you have a question <emphasis>about</emphasis> a question/answer
179    here, please send email to the libstdc++ mailing list, as above.
180    </para>
181  </answer>
182</qandaentry>
183
184</qandadiv>
185
186<!-- License -->
187<qandadiv xml:id="faq.license" xreflabel="License QA">
188
189
190<qandaentry xml:id="faq.license.what">
191  <question xml:id="q-license.what">
192    <para>
193      What are the license terms for libstdc++?
194    </para>
195  </question>
196  <answer xml:id="a-license.what">
197    <para>
198    See <link linkend="manual.intro.status.license">our license description</link>
199    for these and related questions.
200    </para>
201  </answer>
202</qandaentry>
203
204<qandaentry xml:id="faq.license.any_program">
205  <question xml:id="q-license.any_program">
206    <para>
207      So any program which uses libstdc++ falls under the GPL?
208    </para>
209  </question>
210  <answer xml:id="a-license.any_program">
211    <para>
212     No. The special exception permits use of the library in
213     proprietary applications.
214    </para>
215  </answer>
216</qandaentry>
217
218
219<qandaentry xml:id="faq.license.lgpl">
220  <question xml:id="q-license.lgpl">
221    <para>
222      How is that different from the GNU {Lesser,Library} GPL?
223    </para>
224  </question>
225  <answer xml:id="a-license.lgpl">
226    <para>
227      The LGPL requires that users be able to replace the LGPL code with a
228     modified version; this is trivial if the library in question is a C
229     shared library.  But there's no way to make that work with C++, where
230     much of the library consists of inline functions and templates, which
231     are expanded inside the code that uses the library.  So to allow people
232     to replace the library code, someone using the library would have to
233     distribute their own source, rendering the LGPL equivalent to the GPL.
234    </para>
235  </answer>
236</qandaentry>
237
238<qandaentry xml:id="faq.license.what_restrictions">
239  <question xml:id="q-license.what_restrictions">
240    <para>
241      I see. So, what restrictions are there on programs that use the library?
242    </para>
243  </question>
244  <answer xml:id="a-license.what_restrictions">
245    <para>
246      None.  We encourage such programs to be released as free software,
247     but we won't punish you or sue you if you choose otherwise.
248    </para>
249  </answer>
250</qandaentry>
251
252</qandadiv>
253
254<!-- Installation -->
255<qandadiv xml:id="faq.installation" xreflabel="Installation">
256
257
258<qandaentry xml:id="faq.how_to_install">
259  <question xml:id="q-how_to_install">
260    <para>How do I install libstdc++?
261    </para>
262  </question>
263  <answer xml:id="a-how_to_install">
264    <para>
265    Often libstdc++ comes pre-installed as an integral part of many
266    existing GNU/Linux and Unix systems, as well as many embedded
267    development tools. It may be necessary to install extra
268    development packages to get the headers, or the documentation, or
269    the source: please consult your vendor for details.
270    </para>
271    <para>
272    To build and install from the GNU GCC sources, please consult the
273    <link linkend="manual.intro.setup">setup
274    documentation</link> for detailed
275    instructions. You may wish to browse those files ahead
276    of time to get a feel for what's required.
277    </para>
278  </answer>
279</qandaentry>
280
281<qandaentry xml:id="faq.how_to_get_sources">
282  <question xml:id="q-how_to_get_sources">
283    <para>How does one get current libstdc++ sources?
284    </para>
285  </question>
286  <answer xml:id="a-how_to_get_sources">
287    <para>
288    Libstdc++ sources for all official releases can be obtained as
289    part of the GCC sources, available from various sites and
290    mirrors. A full <link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="https://gcc.gnu.org/mirrors.html">list of
291    download sites</link> is provided on the main GCC site.
292    </para>
293    <para>
294    Current libstdc++ sources can always be checked out of the main
295    GCC source repository using the appropriate version control
296    tool. At this time, that tool
297    is <application>Subversion</application>.
298    </para>
299    <para>
300    <application>Subversion</application>, or <acronym>SVN</acronym>, is
301    one of several revision control packages.  It was selected for GNU
302    projects because it's free (speech), free (beer), and very high
303    quality.  The <link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="http://subversion.tigris.org"> Subversion
304    home page</link> has a better description.
305    </para>
306    <para>
307    The <quote>anonymous client checkout</quote> feature of SVN is
308    similar to anonymous FTP in that it allows anyone to retrieve
309    the latest libstdc++ sources.
310    </para>
311    <para>
312    For more information
313    see <link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="https://gcc.gnu.org/svn.html"><acronym>SVN</acronym>
314    details</link>.
315    </para>
316  </answer>
317</qandaentry>
318
319<qandaentry xml:id="faq.how_to_test">
320  <question xml:id="q-how_to_test">
321    <para>How do I know if it works?
322    </para>
323  </question>
324  <answer xml:id="a-how_to_test">
325    <para>
326    Libstdc++ comes with its own validation testsuite, which includes
327    conformance testing, regression testing, ABI testing, and
328    performance testing. Please consult the
329    <link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="http://gcc.gnu.org/install/test.html">testing
330    documentation</link> for GCC and
331    <link linkend="manual.intro.setup.test">Test</link> in the libstdc++
332    manual for more details.
333    </para>
334    <para>
335    If you find bugs in the testsuite programs themselves, or if you
336    think of a new test program that should be added to the suite,
337    <emphasis>please</emphasis> write up your idea and send it to the list!
338    </para>
339  </answer>
340</qandaentry>
341
342<qandaentry xml:id="faq.how_to_set_paths">
343  <question xml:id="q-how_to_set_paths">
344    <para>How do I insure that the dynamically linked library will be found?
345    </para>
346  </question>
347  <answer xml:id="a-how_to_set_paths">
348    <para>
349    Depending on your platform and library version, the error message might
350    be similar to one of the following:
351    </para>
352
353    <screen>
354    ./a.out: error while loading shared libraries: libstdc++.so.6: cannot open shared object file: No such file or directory
355
356    /usr/libexec/ld-elf.so.1: Shared object "libstdc++.so.6" not found
357    </screen>
358
359    <para>
360    This doesn't mean that the shared library isn't installed, only
361    that the dynamic linker can't find it. When a dynamically-linked
362    executable is run the linker finds and loads the required shared
363    libraries by searching a pre-configured list of directories. If
364    the directory where you've installed libstdc++ is not in this list
365    then the libraries won't be found.
366    </para>
367
368    <para>
369    If you already have an older version of libstdc++ installed then the
370    error might look like one of the following instead:
371    </para>
372
373    <screen>
374    ./a.out: /usr/lib/libstdc++.so.6: version `GLIBCXX_3.4.20' not found
375    ./a.out: /usr/lib/libstdc++.so.6: version `CXXABI_1.3.8' not found
376    </screen>
377
378    <para>
379    This means the linker found <filename>/usr/lib/libstdc++.so.6</filename>
380    but that library belongs to an older version of GCC than was used to
381    compile and link the program <filename>a.out</filename> (or some part
382    of it). The program depends on code defined in the newer libstdc++
383    that belongs to the newer version of GCC, so the linker must be told
384    how to find the newer libstdc++ shared library.
385    </para>
386
387    <para>
388    The simplest way to fix this is
389    to use the <envar>LD_LIBRARY_PATH</envar> environment variable,
390    which is a colon-separated list of directories in which the linker
391    will search for shared libraries:
392    </para>
393
394    <screen><command>
395    export LD_LIBRARY_PATH=${prefix}/lib:$LD_LIBRARY_PATH
396    </command></screen>
397
398    <para>
399    Here the shell variable <varname>${prefix}</varname> is assumed to contain
400    the directory prefix where GCC was installed to. The directory containing
401    the library might depend on whether you want the 32-bit or 64-bit copy
402    of the library, so for example would be
403    <filename class="directory">${prefix}/lib64</filename> on some systems.
404    The exact environment variable to use will depend on your
405    platform, e.g. <envar>DYLD_LIBRARY_PATH</envar> for Darwin,
406    <envar>LD_LIBRARY_PATH_32</envar>/<envar>LD_LIBRARY_PATH_64</envar>
407    for Solaris 32-/64-bit,
408    and <envar>SHLIB_PATH</envar> for HP-UX.
409    </para>
410    <para>
411    See the man pages for <command>ld</command>, <command>ldd</command>
412    and <command>ldconfig</command> for more information. The dynamic
413    linker has different names on different platforms but the man page
414    is usually called something such as <filename>ld.so</filename>,
415    <filename>rtld</filename> or <filename>dld.so</filename>.
416    </para>
417    <para>
418    Using <envar>LD_LIBRARY_PATH</envar> is not always the best solution,
419    <link linkend="manual.intro.using.linkage.dynamic">Finding Dynamic or Shared
420    Libraries</link> in the manual gives some alternatives.
421    </para>
422  </answer>
423</qandaentry>
424
425<qandaentry xml:id="faq.what_is_libsupcxx">
426  <question xml:id="q-what_is_libsupcxx">
427    <para>
428      What's libsupc++?
429    </para>
430  </question>
431  <answer xml:id="a-what_is_libsupcxx">
432    <para>
433      If the only functions from <filename class="libraryfile">libstdc++.a</filename>
434      which you need are language support functions (those listed in
435      <link linkend="std.support">clause 18</link> of the
436      standard, e.g., <function>new</function> and
437      <function>delete</function>), then try linking against
438      <filename class="libraryfile">libsupc++.a</filename>, which is a subset of
439      <filename class="libraryfile">libstdc++.a</filename>.  (Using <command>gcc</command>
440      instead of <command>g++</command> and explicitly linking in
441      <filename class="libraryfile">libsupc++.a</filename> via <option>-lsupc++</option>
442      for the final link step will do it).  This library contains only
443      those support routines, one per object file.  But if you are
444      using anything from the rest of the library, such as IOStreams
445      or vectors, then you'll still need pieces from
446      <filename class="libraryfile">libstdc++.a</filename>.
447    </para>
448  </answer>
449</qandaentry>
450
451<qandaentry xml:id="faq.size">
452  <question xml:id="q-size">
453    <para>
454      This library is HUGE!
455    </para>
456  </question>
457  <answer xml:id="a-size">
458    <para>
459    Usually the size of libraries on disk isn't noticeable.  When a
460    link editor (or simply <quote>linker</quote>) pulls things from a
461    static archive library, only the necessary object files are copied
462    into your executable, not the entire library.  Unfortunately, even
463    if you only need a single function or variable from an object file,
464    the entire object file is extracted.  (There's nothing unique to C++
465    or libstdc++ about this; it's just common behavior, given here
466    for background reasons.)
467    </para>
468    <para>
469    Some of the object files which make up
470    <filename class="libraryfile">libstdc++.a</filename> are rather large.
471    If you create a statically-linked executable with
472    <option>-static</option>, those large object files are suddenly part
473    of your executable.  Historically the best way around this was to
474    only place a very few functions (often only a single one) in each
475    source/object file; then extracting a single function is the same
476    as extracting a single <filename>.o</filename> file.  For libstdc++ this
477    is only possible to a certain extent; the object files in question contain
478    template classes and template functions, pre-instantiated, and
479    splitting those up causes severe maintenance headaches.
480    </para>
481    <para>
482    On supported platforms, libstdc++ takes advantage of garbage
483    collection in the GNU linker to get a result similar to separating
484    each symbol into a separate source and object files. On these platforms,
485    GNU ld can place each function and variable into its own
486    section in a <filename>.o</filename> file.  The GNU linker can then perform
487    garbage collection on unused sections; this reduces the situation to only
488    copying needed functions into the executable, as before, but all
489    happens automatically.
490    </para>
491  </answer>
492</qandaentry>
493
494</qandadiv>
495
496
497<!-- Platform-Specific Issues -->
498<qandadiv xml:id="faq.platform-specific" xreflabel="Platform-Specific Issues">
499
500
501<qandaentry xml:id="faq.other_compilers">
502  <question xml:id="q-other_compilers">
503    <para>
504      Can libstdc++ be used with non-GNU compilers?
505    </para>
506  </question>
507  <answer xml:id="a-other_compilers">
508    <para>
509    Perhaps.
510    </para>
511    <para>
512    Since the goal of ISO Standardization is for all C++
513    implementations to be able to share code, libstdc++ should be
514    usable under any ISO-compliant compiler, at least in theory.
515    </para>
516    <para>
517    However, the reality is that libstdc++ is targeted and optimized
518    for GCC/G++. This means that often libstdc++ uses specific,
519    non-standard features of G++ that are not present in older
520    versions of proprietary compilers. It may take as much as a year or two
521    after an official release of GCC that contains these features for
522    proprietary tools to support these constructs.
523    </para>
524    <para>
525    Recent versions of libstdc++ are known to work with the Clang compiler.
526    In the near past, specific released versions of libstdc++ have
527    been known to work with versions of the EDG C++ compiler, and
528    vendor-specific proprietary C++ compilers such as the Intel ICC
529    C++ compiler.
530    </para>
531
532  </answer>
533</qandaentry>
534
535<qandaentry xml:id="faq.solaris_long_long">
536  <question xml:id="q-solaris_long_long">
537    <para>
538      No '<type>long long</type>' type on Solaris?
539    </para>
540  </question>
541  <answer xml:id="a-solaris_long_long">
542    <para>
543    By default we try to support the C99 <type>long long</type> type.
544    This requires that certain functions from your C library be present.
545    </para>
546    <para>
547    Up through release 3.0.2 the platform-specific tests performed by
548    libstdc++ were too general, resulting in a conservative approach
549    to enabling the <type>long long</type> code paths. The most
550    commonly reported platform affected was Solaris.
551    </para>
552    <para>
553    This has been fixed for libstdc++ releases greater than 3.0.3.
554    </para>
555  </answer>
556</qandaentry>
557
558<qandaentry xml:id="faq.predefined">
559  <question xml:id="q-predefined">
560    <para>
561      <constant>_XOPEN_SOURCE</constant> and <constant>_GNU_SOURCE</constant> are always defined?
562    </para>
563  </question>
564  <answer xml:id="a-predefined">
565      <para>On Solaris, <command>g++</command> (but not <command>gcc</command>)
566         always defines the preprocessor macro
567	 <constant>_XOPEN_SOURCE</constant>.  On GNU/Linux, the same happens
568         with <constant>_GNU_SOURCE</constant>.  (This is not an exhaustive list;
569         other macros and other platforms are also affected.)
570      </para>
571      <para>These macros are typically used in C library headers, guarding new
572         versions of functions from their older versions.  The C++98 standard
573         library includes the C standard library, but it requires the C90
574         version, which for backwards-compatibility reasons is often not the
575         default for many vendors.
576      </para>
577      <para>More to the point, the C++ standard requires behavior which is only
578         available on certain platforms after certain symbols are defined.
579         Usually the issue involves I/O-related typedefs.  In order to
580         ensure correctness, the compiler simply predefines those symbols.
581      </para>
582      <para>Note that it's not enough to <literal>#define</literal> them only when the library is
583         being built (during installation).  Since we don't have an 'export'
584         keyword, much of the library exists as headers, which means that
585         the symbols must also be defined as your programs are parsed and
586         compiled.
587      </para>
588      <para>To see which symbols are defined, look for
589         <varname>CPLUSPLUS_CPP_SPEC</varname> in
590         the gcc config headers for your target (and try changing them to
591         see what happens when building complicated code).  You can also run
592         <command>g++ -E -dM - &lt; /dev/null"</command> to display
593         a list of predefined macros for any particular installation.
594      </para>
595      <para>This has been discussed on the mailing lists
596         <link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="http://gcc.gnu.org/cgi-bin/htsearch?method=and&amp;format=builtin-long&amp;sort=score&amp;words=_XOPEN_SOURCE+Solaris">quite a bit</link>.
597      </para>
598      <para>This method is something of a wart.  We'd like to find a cleaner
599         solution, but nobody yet has contributed the time.
600      </para>
601
602  </answer>
603</qandaentry>
604
605<qandaentry xml:id="faq.darwin_ctype">
606  <question xml:id="q-darwin_ctype">
607    <para>
608      Mac OS X <filename class="headerfile">ctype.h</filename> is broken! How can I fix it?
609    </para>
610  </question>
611  <answer xml:id="a-darwin_ctype">
612      <note>
613         <para>This answer is old and probably no longer be relevant.</para>
614      </note>
615      <para>
616         This was a long-standing bug in the OS X support.  Fortunately, the
617         <link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="http://gcc.gnu.org/ml/gcc/2002-03/msg00817.html">patch</link>
618	 was quite simple, and well-known.
619      </para>
620
621  </answer>
622</qandaentry>
623
624<qandaentry xml:id="faq.threads_i386">
625  <question xml:id="q-threads_i386">
626    <para>
627      Threading is broken on i386?
628    </para>
629  </question>
630  <answer xml:id="a-threads_i386">
631      <note>
632         <para>This answer is old and probably no longer be relevant.</para>
633      </note>
634      <para>Support for atomic integer operations was broken on i386
635         platforms.  The assembly code accidentally used opcodes that are
636         only available on the i486 and later.  So if you configured GCC
637         to target, for example, i386-linux, but actually used the programs
638         on an i686, then you would encounter no problems.  Only when
639         actually running the code on a i386 will the problem appear.
640      </para>
641      <para>This is fixed in 3.2.2.
642      </para>
643
644  </answer>
645</qandaentry>
646
647<qandaentry xml:id="faq.atomic_mips">
648  <question xml:id="q-atomic_mips">
649    <para>
650      MIPS atomic operations
651    </para>
652  </question>
653  <answer xml:id="a-atomic_mips">
654    <note>
655      <para>This answer is old and probably no longer be relevant.</para>
656    </note>
657    <para>
658    The atomic locking routines for MIPS targets requires MIPS II
659    and later.  A patch went in just after the 3.3 release to
660    make mips* use the generic implementation instead.  You can also
661    configure for mipsel-elf as a workaround.
662    </para>
663    <para>
664    The mips*-*-linux* port continues to use the MIPS II routines, and more
665    work in this area is expected.
666    </para>
667  </answer>
668</qandaentry>
669
670<qandaentry xml:id="faq.linux_glibc">
671  <question xml:id="q-linux_glibc">
672    <para>
673      Recent GNU/Linux glibc required?
674    </para>
675  </question>
676  <answer xml:id="a-linux_glibc">
677      <para>When running on GNU/Linux, libstdc++ 3.2.1 (shared library version
678         5.0.1) and later uses localization and formatting code from the system
679         C library (glibc) version 2.2.5 which contains necessary bugfixes.
680         All GNU/Linux distros make more recent versions available now.
681         libstdc++ 4.6.0 and later require glibc 2.3 or later for this
682         localization and formatting code.
683      </para>
684      <para>The guideline is simple:  the more recent the C++ library, the
685         more recent the C library.  (This is also documented in the main
686         GCC installation instructions.)
687      </para>
688
689  </answer>
690</qandaentry>
691
692<qandaentry xml:id="faq.freebsd_wchar">
693  <question xml:id="q-freebsd_wchar">
694    <para>
695      Can't use wchar_t/wstring on FreeBSD
696    </para>
697  </question>
698  <answer xml:id="a-freebsd_wchar">
699    <note>
700      <para>This answer is old and probably no longer be relevant.</para>
701    </note>
702    <para>
703    Older versions of FreeBSD's C library do not have sufficient
704    support for wide character functions, and as a result the
705    libstdc++ configury decides that <type>wchar_t</type> support should be
706    disabled. In addition, the libstdc++ platform checks that
707    enabled <type>wchar_t</type> were quite strict, and not granular
708    enough to detect when the minimal support to
709    enable <type>wchar_t</type> and C++ library structures
710    like <classname>wstring</classname> were present. This impacted Solaris,
711    Darwin, and BSD variants, and is fixed in libstdc++ versions post 4.1.0.
712    </para>
713    <para>
714    </para>
715  </answer>
716</qandaentry>
717
718</qandadiv>
719
720
721<!-- Known Bugs -->
722<qandadiv xml:id="faq.known_bugs" xreflabel="Known Bugs">
723
724
725<qandaentry xml:id="faq.what_works">
726  <question xml:id="q-what_works">
727    <para>
728      What works already?
729    </para>
730  </question>
731  <answer xml:id="a-what_works">
732    <para>
733    Short answer: Pretty much everything <emphasis>works</emphasis>
734    except for some corner cases.  Support for localization
735    in <classname>locale</classname> may be incomplete on some non-GNU
736    platforms. Also dependent on the underlying platform is support
737    for <type>wchar_t</type> and <type>long
738    long</type> specializations, and details of thread support.
739    </para>
740    <para>
741    Long answer: See the implementation status pages for
742    <link linkend="status.iso.1998">C++98</link>,
743    <link linkend="status.iso.tr1">TR1</link>, and
744    <link linkend="status.iso.2011">C++11</link>.
745    <link linkend="status.iso.2014">C++14</link>.
746    </para>
747  </answer>
748</qandaentry>
749
750<qandaentry xml:id="faq.standard_bugs">
751  <question xml:id="q-standard_bugs">
752    <para>
753      Bugs in the ISO C++ language or library specification
754    </para>
755  </question>
756  <answer xml:id="a-standard_bugs">
757    <para>
758    Unfortunately, there are some.
759    </para>
760    <para>
761    For those people who are not part of the ISO Library Group
762    (i.e., nearly all of us needing to read this page in the first
763    place), a public list of the library defects is occasionally
764    published on <link xmlns:xlink="http://www.w3.org/1999/xlink"
765    xlink:href="http://www.open-std.org/jtc1/sc22/wg21/">the WG21
766    website</link>.
767    Many of these issues have resulted in code changes in libstdc++.
768    </para>
769    <para>
770    If you think you've discovered a new bug that is not listed,
771    please post a message describing your problem to the author of
772    the library issues list.
773    </para>
774  </answer>
775</qandaentry>
776
777<qandaentry xml:id="faq.compiler_bugs">
778  <question xml:id="q-compiler_bugs">
779    <para>
780      Bugs in the compiler (gcc/g++) and not libstdc++
781    </para>
782  </question>
783  <answer xml:id="a-compiler_bugs">
784    <para>
785    On occasion, the compiler is wrong. Please be advised that this
786    happens much less often than one would think, and avoid jumping to
787    conclusions.
788    </para>
789    <para>
790    First, examine the ISO C++ standard. Second, try another compiler
791    or an older version of the GNU compilers. Third, you can find more
792    information on the libstdc++ and the GCC mailing lists: search
793    these lists with terms describing your issue.
794    </para>
795    <para>
796    Before reporting a bug, please examine the
797    <link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="http://gcc.gnu.org/bugs/">bugs database</link> with the
798    category set to <quote>g++</quote>.
799    </para>
800  </answer>
801</qandaentry>
802
803</qandadiv>
804
805<!-- Known Non-Bugs -->
806<qandadiv xml:id="faq.known_non-bugs" xreflabel="Known Non-Bugs">
807
808
809<qandaentry xml:id="faq.stream_reopening_fails">
810  <question xml:id="q-stream_reopening_fails">
811    <para>
812      Reopening a stream fails
813    </para>
814  </question>
815  <answer xml:id="a-stream_reopening_fails">
816    <para>
817    One of the most-reported non-bug reports. Executing a sequence like:
818    </para>
819
820    <programlisting>
821    #include &lt;fstream&gt;
822    ...
823    std::fstream  fs("a_file");
824    // .
825    // . do things with fs...
826    // .
827    fs.close();
828    fs.open("a_new_file");
829    </programlisting>
830
831    <para>
832    All operations on the re-opened <varname>fs</varname> will fail, or at
833    least act very strangely.  Yes, they often will, especially if
834    <varname>fs</varname> reached the EOF state on the previous file.  The
835    reason is that the state flags are <emphasis>not</emphasis> cleared
836    on a successful call to open().  The standard unfortunately did
837    not specify behavior in this case, and to everybody's great sorrow,
838    the <link linkend="manual.intro.status.bugs">proposed LWG resolution in
839      DR #22</link> is to leave the flags unchanged.  You must insert a call
840    to <function>fs.clear()</function> between the calls to close() and open(),
841    and then everything will work like we all expect it to work.
842    <emphasis>Update:</emphasis> for GCC 4.0 we implemented the resolution
843    of <link linkend="manual.intro.status.bugs">DR #409</link> and open()
844    now calls <function>clear()</function> on success!
845    </para>
846  </answer>
847</qandaentry>
848
849<qandaentry xml:id="faq.wefcxx_verbose">
850  <question xml:id="q-wefcxx_verbose">
851    <para>
852      -Weffc++ complains too much
853    </para>
854  </question>
855  <answer xml:id="a-wefcxx_verbose">
856    <para>
857    Many warnings are emitted when <option>-Weffc++</option> is used.  Making
858    libstdc++ <option>-Weffc++</option>-clean is not a goal of the project,
859    for a few reasons.  Mainly, that option tries to enforce
860    object-oriented programming, while the Standard Library isn't
861    necessarily trying to be OO.
862    </para>
863    <para>
864    We do, however, try to have libstdc++ sources as clean as possible. If
865    you see some simple changes that pacify <option>-Weffc++</option>
866    without other drawbacks, send us a patch.
867    </para>
868  </answer>
869</qandaentry>
870
871<qandaentry xml:id="faq.ambiguous_overloads">
872  <question xml:id="q-ambiguous_overloads">
873    <para>
874      Ambiguous overloads after including an old-style header
875    </para>
876  </question>
877  <answer xml:id="a-ambiguous_overloads">
878    <para>
879    Another problem is the <literal>rel_ops</literal> namespace and the template
880    comparison operator functions contained therein.  If they become
881    visible in the same namespace as other comparison functions
882    (e.g., <quote>using</quote> them and the &lt;iterator&gt; header),
883    then you will suddenly be faced with huge numbers of ambiguity
884    errors.  This was discussed on the -v3 list; Nathan Myers
885    <link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="http://gcc.gnu.org/ml/libstdc++/2001-01/msg00247.html">sums
886      things up here</link>.  The collisions with vector/string iterator
887    types have been fixed for 3.1.
888    </para>
889  </answer>
890</qandaentry>
891
892<qandaentry xml:id="faq.v2_headers">
893  <question xml:id="q-v2_headers">
894    <para>
895      The g++-3 headers are <emphasis>not ours</emphasis>
896    </para>
897  </question>
898  <answer xml:id="a-v2_headers">
899      <para>
900	If you are using headers in
901	<filename class="directory">${prefix}/include/g++-3</filename>, or if
902	the installed library's name looks like
903	<filename class="libraryfile">libstdc++-2.10.a</filename> or
904	<filename class="libraryfile">libstdc++-libc6-2.10.so</filename>, then
905	you are using the old libstdc++-v2 library, which is non-standard and
906	unmaintained.  Do not report problems with -v2 to the -v3
907	mailing list.
908      </para>
909      <para>
910	For GCC versions 3.0 and 3.1 the libstdc++ header files are installed in
911	<filename class="directory">${prefix}/include/g++-v3</filename>
912	(see the 'v'?).  Starting with version 3.2 the headers are installed in
913	<filename class="directory">${prefix}/include/c++/${version}</filename>
914	as this prevents headers from previous versions being found by mistake.
915      </para>
916
917  </answer>
918</qandaentry>
919
920<qandaentry xml:id="faq.boost_concept_checks">
921  <question xml:id="q-boost_concept_checks">
922    <para>
923      Errors about <emphasis>*Concept</emphasis> and
924      <emphasis>constraints</emphasis> in the STL
925    </para>
926  </question>
927  <answer xml:id="a-boost_concept_checks">
928    <para>
929    If you see compilation errors containing messages about
930    <errortext>foo Concept</errortext> and something to do with a
931    <errortext>constraints</errortext> member function, then most
932    likely you have violated one of the requirements for types used
933    during instantiation of template containers and functions.  For
934    example, EqualityComparableConcept appears if your types must be
935    comparable with == and you have not provided this capability (a
936    typo, or wrong visibility, or you just plain forgot, etc).
937    </para>
938    <para>
939    More information, including how to optionally enable/disable the
940    checks, is available in the
941    <link linkend="std.diagnostics.concept_checking">Diagnostics</link>.
942    chapter of the manual.
943    </para>
944  </answer>
945</qandaentry>
946
947<qandaentry xml:id="faq.dlopen_crash">
948  <question xml:id="q-dlopen_crash">
949    <para>
950      Program crashes when using library code in a
951      dynamically-loaded library
952    </para>
953  </question>
954  <answer xml:id="a-dlopen_crash">
955    <para>
956    If you are using the C++ library across dynamically-loaded
957    objects, make certain that you are passing the correct options
958    when compiling and linking:
959    </para>
960
961    <literallayout class="normal">
962    Compile your library components:
963    <command>g++ -fPIC -c a.cc</command>
964    <command>g++ -fPIC -c b.cc</command>
965    ...
966    <command>g++ -fPIC -c z.cc</command>
967
968    Create your library:
969    <command>g++ -fPIC -shared -rdynamic -o libfoo.so a.o b.o ... z.o</command>
970
971    Link the executable:
972    <command>g++ -fPIC -rdynamic -o foo ... -L. -lfoo -ldl</command>
973    </literallayout>
974  </answer>
975</qandaentry>
976
977<qandaentry xml:id="faq.memory_leaks">
978  <question xml:id="q-memory_leaks">
979    <para>
980      <quote>Memory leaks</quote> in containers
981    </para>
982  </question>
983  <answer xml:id="a-memory_leaks">
984    <para>
985    A few people have reported that the standard containers appear
986    to leak memory when tested with memory checkers such as
987    <link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="http://valgrind.org/"><command>valgrind</command></link>.
988    Under some configurations the library's allocators keep free memory in a
989    pool for later reuse, rather than returning it to the OS.  Although
990    this memory is always reachable by the library and is never
991    lost, memory debugging tools can report it as a leak.  If you
992    want to test the library for memory leaks please read
993    <link linkend="debug.memory">Tips for memory leak hunting</link>
994    first.
995    </para>
996  </answer>
997</qandaentry>
998
999<qandaentry xml:id="faq.list_size_on">
1000  <question xml:id="q-list_size_on">
1001    <para>
1002      list::size() is O(n)!
1003    </para>
1004  </question>
1005  <answer xml:id="a-list_size_on">
1006    <para>
1007    See
1008    the <link linkend="std.containers">Containers</link>
1009    chapter.
1010    </para>
1011  </answer>
1012</qandaentry>
1013
1014<qandaentry xml:id="faq.easy_to_fix">
1015  <question xml:id="q-easy_to_fix">
1016    <para>
1017      Aw, that's easy to fix!
1018    </para>
1019  </question>
1020  <answer xml:id="a-easy_to_fix">
1021    <para>
1022    If you have found a bug in the library and you think you have
1023    a working fix, then send it in!  The main GCC site has a page
1024    on <link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="http://gcc.gnu.org/contribute.html">submitting
1025    patches</link> that covers the procedure, but for libstdc++ you
1026    should also send the patch to our mailing list in addition to
1027    the GCC patches mailing list.  The libstdc++
1028    <link linkend="appendix.contrib">contributors' page</link>
1029    also talks about how to submit patches.
1030    </para>
1031    <para>
1032    In addition to the description, the patch, and the ChangeLog
1033    entry, it is a Good Thing if you can additionally create a small
1034    test program to test for the presence of the bug that your patch
1035    fixes.  Bugs have a way of being reintroduced; if an old bug
1036    creeps back in, it will be caught immediately by the testsuite -
1037    but only if such a test exists.
1038    </para>
1039  </answer>
1040</qandaentry>
1041
1042</qandadiv>
1043
1044
1045<!-- Miscellaneous -->
1046<qandadiv xml:id="faq.misc" xreflabel="Miscellaneous">
1047
1048
1049<qandaentry xml:id="faq.iterator_as_pod">
1050  <question xml:id="faq.iterator_as_pod_q">
1051    <para>
1052      string::iterator is not char*; vector&lt;T&gt;::iterator is not T*
1053    </para>
1054  </question>
1055  <answer xml:id="faq.iterator_as_pod_a">
1056    <para>
1057    If you have code that depends on container&lt;T&gt; iterators
1058    being implemented as pointer-to-T, your code is broken. It's
1059    considered a feature, not a bug, that libstdc++ points this out.
1060    </para>
1061    <para>
1062    While there are arguments for iterators to be implemented in
1063    that manner, A) they aren't very good ones in the long term,
1064    and B) they were never guaranteed by the Standard anyway.  The
1065    type-safety achieved by making iterators a real class rather
1066    than a typedef for <type>T*</type> outweighs nearly all opposing
1067    arguments.
1068    </para>
1069    <para>
1070    Code which does assume that a vector iterator <varname>i</varname>
1071    is a pointer can often be fixed by changing <varname>i</varname> in
1072    certain expressions to <varname>&amp;*i</varname>.  Future revisions
1073    of the Standard are expected to bless this usage for
1074    vector&lt;&gt; (but not for basic_string&lt;&gt;).
1075    </para>
1076  </answer>
1077</qandaentry>
1078
1079<qandaentry xml:id="faq.what_is_next">
1080  <question xml:id="q-what_is_next">
1081    <para>
1082      What's next after libstdc++?
1083    </para>
1084  </question>
1085  <answer xml:id="a-what_is_next">
1086      <para>
1087	Hopefully, not much.  The goal of libstdc++ is to produce a
1088	fully-compliant, fully-portable Standard Library.  After that,
1089	we're mostly done: there won't <emphasis>be</emphasis> any
1090	more compliance work to do.
1091      </para>
1092      <para>
1093	There is an effort underway to add significant extensions to
1094	the standard library specification.  The latest version of
1095	this effort is described in
1096         <link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2005/n1836.pdf">
1097         The C++ Library Technical Report 1</link>.
1098      </para>
1099  </answer>
1100</qandaentry>
1101
1102<qandaentry xml:id="faq.sgi_stl">
1103  <question xml:id="q-sgi_stl">
1104    <para>
1105      What about the STL from SGI?
1106    </para>
1107  </question>
1108  <answer xml:id="a-sgi_stl">
1109    <para>
1110      The <link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="http://www.sgi.com/tech/stl/">STL from SGI</link>,
1111    version 3.3, was the final merge of the STL codebase.  The
1112    code in libstdc++ contains many fixes and changes, and
1113    the SGI code is no longer under active
1114    development.  We expect that no future merges will take place.
1115    </para>
1116    <para>
1117    In particular, <classname>string</classname> is not from SGI and makes no
1118    use of their "rope" class (which is included as an
1119    optional extension), nor is <classname>valarray</classname> and some others.
1120    Classes like <classname>vector&lt;&gt;</classname> are, but have been
1121    extensively modified.
1122    </para>
1123    <para>
1124    More information on the evolution of libstdc++ can be found at the
1125    <link linkend="appendix.porting.api">API
1126    evolution</link>
1127    and <link linkend="manual.appendix.porting.backwards">backwards
1128    compatibility</link> documentation.
1129    </para>
1130    <para>
1131    The <link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="http://www.sgi.com/tech/stl/FAQ.html">FAQ</link>
1132    for SGI's STL is still recommended reading.
1133    </para>
1134  </answer>
1135</qandaentry>
1136
1137<qandaentry xml:id="faq.extensions_and_backwards_compat">
1138  <question xml:id="q-extensions_and_backwards_compat">
1139    <para>
1140      Extensions and Backward Compatibility
1141    </para>
1142  </question>
1143  <answer xml:id="a-extensions_and_backwards_compat">
1144    <para>
1145      See the <link linkend="manual.appendix.porting.backwards">link</link> on backwards compatibility and <link linkend="appendix.porting.api">link</link> on evolution.
1146    </para>
1147  </answer>
1148</qandaentry>
1149
1150<qandaentry xml:id="faq.tr1_support">
1151  <question xml:id="q-tr1_support">
1152    <para>
1153      Does libstdc++ support TR1?
1154    </para>
1155  </question>
1156  <answer xml:id="a-tr1_support">
1157    <para>
1158    Yes.
1159    </para>
1160    <para>
1161    The C++ Standard Library Technical Report adds many new features to
1162    the library.  The latest version of this effort is described in
1163    <link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2005/n1836.pdf">
1164         Technical Report 1</link>.
1165    </para>
1166    <para>
1167    The implementation status of TR1 in libstdc++ can be tracked <link linkend="status.iso.tr1">on the TR1 status
1168    page</link>.
1169    </para>
1170  </answer>
1171</qandaentry>
1172
1173<qandaentry xml:id="faq.get_iso_cxx">
1174  <question xml:id="q-get_iso_cxx">
1175    <para>How do I get a copy of the ISO C++ Standard?
1176    </para>
1177  </question>
1178  <answer xml:id="a-get_iso_cxx">
1179    <para>
1180    Copies of the full ISO 14882 standard are available on line via
1181    the ISO mirror site for committee members.  Non-members, or those
1182    who have not paid for the privilege of sitting on the committee
1183    and sustained their two-meeting commitment for voting rights, may
1184    get a copy of the standard from their respective national
1185    standards organization.  In the USA, this national standards
1186    organization is ANSI and their website is
1187    right <link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="http://www.ansi.org">here</link>.  (And if
1188    you've already registered with them, clicking this link will take
1189    you to directly to the place where you can
1190    <link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="http://webstore.ansi.org/RecordDetail.aspx?sku=ISO%2FIEC+14882:2003">buy the standard on-line</link>.
1191    </para>
1192    <para>
1193    Who is your country's member body?  Visit the
1194    <link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="http://www.iso.ch/">ISO homepage</link> and find out!
1195    </para>
1196    <para>
1197    The 2003 version of the standard (the 1998 version plus TC1) is
1198    available in print, ISBN 0-470-84674-7.
1199    </para>
1200  </answer>
1201</qandaentry>
1202
1203<qandaentry xml:id="faq.what_is_abi">
1204  <question xml:id="q-what_is_abi">
1205    <para>
1206      What's an ABI and why is it so messy?
1207    </para>
1208  </question>
1209  <answer xml:id="a-what_is_abi">
1210    <para>
1211    <acronym>ABI</acronym> stands for <quote>Application Binary
1212    Interface</quote>.  Conventionally, it refers to a great
1213    mass of details about how arguments are arranged on the call
1214    stack and/or in registers, and how various types are arranged
1215    and padded in structs.  A single CPU design may suffer
1216    multiple ABIs designed by different development tool vendors
1217    who made different choices, or even by the same vendor for
1218    different target applications or compiler versions.  In ideal
1219    circumstances the CPU designer presents one ABI and all the
1220    OSes and compilers use it.  In practice every ABI omits
1221    details that compiler implementers (consciously or
1222    accidentally) must choose for themselves.
1223    </para>
1224    <para>
1225    That ABI definition suffices for compilers to generate code so a
1226    program can interact safely with an OS and its lowest-level libraries.
1227    Users usually want an ABI to encompass more detail, allowing libraries
1228    built with different compilers (or different releases of the same
1229    compiler!) to be linked together.  For C++, this includes many more
1230    details than for C, and most CPU designers (for good reasons elaborated
1231    below) have not stepped up to publish C++ ABIs.  Such an ABI has been
1232    defined for the Itanium architecture (see
1233    <link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="http://mentorembedded.github.io/cxx-abi/">C++
1234    ABI for Itanium</link>) and that is used by G++ and other compilers
1235    as the de facto standard ABI on many common architectures (including x86).
1236    G++ can also use the ARM architecture's EABI, for embedded
1237    systems relying only on a <quote>free-standing implementation</quote> that
1238    doesn't include (much of) the standard library, and the GNU EABI for
1239    hosted implementations on ARM.  Those ABIs cover low-level details
1240    such as virtual function implementation, struct inheritance layout,
1241    name mangling, and exception handling.
1242   </para>
1243    <para>
1244    A useful C++ ABI must also incorporate many details of the standard
1245    library implementation.  For a C ABI, the layouts of a few structs
1246    (such as <type>FILE</type>, <type>stat</type>, <type>jmpbuf</type>,
1247    and the like) and a few macros suffice.
1248    For C++, the details include the complete set of names of functions
1249    and types used, the offsets of class members and virtual functions,
1250    and the actual definitions of all inlines.  C++ exposes many more
1251    library details to the caller than C does.  It makes defining
1252    a complete ABI a much bigger undertaking, and requires not just
1253    documenting library implementation details, but carefully designing
1254    those details so that future bug fixes and optimizations don't
1255    force breaking the ABI.
1256    </para>
1257    <para>
1258    There are ways to help isolate library implementation details from the
1259    ABI, but they trade off against speed.  Library details used in inner
1260    loops (e.g., <function>getchar</function>) must be exposed and frozen for
1261    all time, but many others may reasonably be kept hidden from user code,
1262    so they may later be changed.  Deciding which, and implementing
1263    the decisions, must happen before you can reasonably document a
1264    candidate C++ ABI that encompasses the standard library.
1265    </para>
1266  </answer>
1267</qandaentry>
1268
1269<qandaentry xml:id="faq.size_equals_capacity">
1270  <question xml:id="q-size_equals_capacity">
1271    <para>
1272      How do I make std::vector&lt;T&gt;::capacity() == std::vector&lt;T&gt;::size?
1273    </para>
1274  </question>
1275  <answer xml:id="a-size_equals_capacity">
1276    <para>
1277    The standard idiom for deallocating a <classname>vector&lt;T&gt;</classname>'s
1278    unused memory is to create a temporary copy of the vector and swap their
1279    contents, e.g. for <classname>vector&lt;T&gt; v</classname>
1280    </para>
1281    <literallayout class="normal">
1282     std::vector&lt;T&gt;(v).swap(v);
1283    </literallayout>
1284    <para>
1285    The copy will take O(n) time and the swap is constant time.
1286    </para>
1287    <para>
1288    See <link linkend="strings.string.shrink">Shrink-to-fit
1289    strings</link> for a similar solution for strings.
1290    </para>
1291  </answer>
1292</qandaentry>
1293
1294</qandadiv>
1295
1296
1297<!-- FAQ ends here -->
1298</qandaset>
1299
1300</article>
1301
1302</book>
1303