On 03/01/19 22:44 +0000, Jonathan Wakely wrote:
On 03/01/19 22:07 +0000, Jonathan Wakely wrote:
On 03/01/19 20:38 +0000, Jonathan Wakely wrote:
There are a number of UTF-8 characters in comments which add no value
and can be replaced with ASCII equivalents, or removed entirely for the
section sign (U+00A7).

        PR libstdc++/88607
        * include/bits/forward_list.h: Replace UTF-8 "ligature fi" character.
        * include/debug/forward_list: Likewise.
        * include/experimental/bits/shared_ptr.h: Remove UTF-8 "section sign"
        character.
        * include/experimental/chrono: Likewise.
        * include/experimental/functional: Likewise.
        * include/experimental/ratio: Likewise.
        * include/experimental/system_error: Likewise.
        * include/experimental/tuple: Likewise.
        * include/experimental/type_traits: Likewise.
        * include/parallel/workstealing.h: Replace UTF-8 "en dash" character.
        * include/parallel/multiseq_selection.h: Likewise.

This replaces some more non-ASCII characters.

Tested powerpc64-linux, committed to trunk.

The tests added by this patch would probably be a good idea, but I'm
not sure if -finput-charset=ascii works for all targets.

This is committed to trunk now. If some targets fail the test we can
deal with them as needed.


commit 53a31b41d06059fdaf1f09fd66f5d9e219246759
Author: Jonathan Wakely <jwak...@redhat.com>
Date:   Thu Jan 3 22:18:14 2019 +0000

   PR libstdc++/88607 add tests using -finput-charset=ascii
This verifies that the <bits/extc++.h> header can be compiled with ASCII
   as the input character set.
PR libstdc++/88607
           * testsuite/17_intro/headers/c++1998/charset.cc: New test.
           * testsuite/17_intro/headers/c++2011/charset.cc: New test.
           * testsuite/17_intro/headers/c++2014/charset.cc: New test.
           * testsuite/17_intro/headers/c++2017/charset.cc: New test.
           * testsuite/17_intro/headers/c++2020/charset.cc: New test.

diff --git a/libstdc++-v3/testsuite/17_intro/headers/c++1998/charset.cc 
b/libstdc++-v3/testsuite/17_intro/headers/c++1998/charset.cc
new file mode 100644
index 00000000000..864c64ef831
--- /dev/null
+++ b/libstdc++-v3/testsuite/17_intro/headers/c++1998/charset.cc
@@ -0,0 +1,4 @@
+// { dg-options "-finput-charset=ascii" }
+// { dg-do compile }
+
+#include <bits/extc++.h>
diff --git a/libstdc++-v3/testsuite/17_intro/headers/c++2011/charset.cc 
b/libstdc++-v3/testsuite/17_intro/headers/c++2011/charset.cc
new file mode 100644
index 00000000000..864c64ef831
--- /dev/null
+++ b/libstdc++-v3/testsuite/17_intro/headers/c++2011/charset.cc
@@ -0,0 +1,4 @@
+// { dg-options "-finput-charset=ascii" }
+// { dg-do compile }
+
+#include <bits/extc++.h>
diff --git a/libstdc++-v3/testsuite/17_intro/headers/c++2014/charset.cc 
b/libstdc++-v3/testsuite/17_intro/headers/c++2014/charset.cc
new file mode 100644
index 00000000000..864c64ef831
--- /dev/null
+++ b/libstdc++-v3/testsuite/17_intro/headers/c++2014/charset.cc
@@ -0,0 +1,4 @@
+// { dg-options "-finput-charset=ascii" }
+// { dg-do compile }
+
+#include <bits/extc++.h>
diff --git a/libstdc++-v3/testsuite/17_intro/headers/c++2017/charset.cc 
b/libstdc++-v3/testsuite/17_intro/headers/c++2017/charset.cc
new file mode 100644
index 00000000000..864c64ef831
--- /dev/null
+++ b/libstdc++-v3/testsuite/17_intro/headers/c++2017/charset.cc
@@ -0,0 +1,4 @@
+// { dg-options "-finput-charset=ascii" }
+// { dg-do compile }
+
+#include <bits/extc++.h>
diff --git a/libstdc++-v3/testsuite/17_intro/headers/c++2020/charset.cc 
b/libstdc++-v3/testsuite/17_intro/headers/c++2020/charset.cc
new file mode 100644
index 00000000000..864c64ef831
--- /dev/null
+++ b/libstdc++-v3/testsuite/17_intro/headers/c++2020/charset.cc
@@ -0,0 +1,4 @@
+// { dg-options "-finput-charset=ascii" }
+// { dg-do compile }
+
+#include <bits/extc++.h>

Reply via email to