* [committed] libstdc++: Update outdated default -std in testing docs
@ 2023-09-08 18:15 Jonathan Wakely
0 siblings, 0 replies; only message in thread
From: Jonathan Wakely @ 2023-09-08 18:15 UTC (permalink / raw)
To: libstdc++, gcc-patches
Pushed to gcc-13 (I've removed/rewritten this text on trunk).
I'll push to the older branches too.
-- >8 --
libstdc++-v3/ChangeLog:
* doc/xml/manual/test.xml: Update reference to -std=gnu++14 as
the default.
* doc/html/manual/test.html: Regenerate.
---
libstdc++-v3/doc/html/manual/test.html | 10 +++++-----
libstdc++-v3/doc/xml/manual/test.xml | 10 +++++-----
2 files changed, 10 insertions(+), 10 deletions(-)
diff --git a/libstdc++-v3/doc/xml/manual/test.xml b/libstdc++-v3/doc/xml/manual/test.xml
index 964c53d2632..9853a284814 100644
--- a/libstdc++-v3/doc/xml/manual/test.xml
+++ b/libstdc++-v3/doc/xml/manual/test.xml
@@ -767,7 +767,7 @@ cat 27_io/objects/char/3_xin.in | a.out</programlisting>
be run for a specific standard (and not later standards) using an
effective target like <literal>c++11_only</literal>. However, this means
the test will be skipped by default (because the default mode is
- <literal>gnu++14</literal>), and so will only run when
+ <literal>gnu++17</literal>), and so will only run when
<option>-std=gnu++11</option> or <option>-std=c++11</option> is used
explicitly. For tests that require a specific standard it is better to
use a <literal>dg-options</literal> directive:
@@ -783,13 +783,13 @@ cat 27_io/objects/char/3_xin.in | a.out</programlisting>
Similarly, tests which depend on a newer standard than the default
must use <literal>dg-options</literal> instead of (or in addition to)
an effective target, so that they are not skipped by default.
- For example, tests for C++17 features should use
-<programlisting> // { dg-options "-std=gnu++17" }</programlisting>
+ For example, tests for C++20 features should use
+<programlisting> // { dg-options "-std=gnu++20" }</programlisting>
before any <literal>dg-do</literal> such as:
-<programlisting> // { dg-do run "c++17" }</programlisting>
+<programlisting> // { dg-do run { target c++20 } }</programlisting>
The <literal>dg-options</literal> directive must come first, so that
the <literal>-std</literal> flag has already been added to the options
- before checking the <literal>c++17</literal> target.
+ before checking the <literal>c++20</literal> effective target.
</para>
<section xml:id="tests.dg.examples"><info><title>Examples of Test Directives</title></info>
--
2.41.0
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2023-09-08 18:16 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-09-08 18:15 [committed] libstdc++: Update outdated default -std in testing docs Jonathan Wakely
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).