public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [pushed] doc: Update -fchar8_t documentation
@ 2023-02-07 16:48 Marek Polacek
  0 siblings, 0 replies; only message in thread
From: Marek Polacek @ 2023-02-07 16:48 UTC (permalink / raw)
  To: GCC Patches

Since C++20 P2513R4, char8_t Compatibility and Portability Fix it is
no longer true that

  char ca[] = u8"xx";

causes an error so adjust the example for -fchar8_t.

Applied.

gcc/ChangeLog:

	* doc/invoke.texi: Update -fchar8_t documentation.
---
 gcc/doc/invoke.texi | 2 --
 1 file changed, 2 deletions(-)

diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi
index 1eda0e0396b..51447a78584 100644
--- a/gcc/doc/invoke.texi
+++ b/gcc/doc/invoke.texi
@@ -3057,8 +3057,6 @@ following code is well-formed under ISO C++11, but is ill-formed when
 @option{-fchar8_t} is specified.
 
 @smallexample
-char ca[] = u8"xx";     // error: char-array initialized from wide
-                        //        string
 const char *cp = u8"xx";// error: invalid conversion from
                         //        `const char8_t*' to `const char*'
 int f(const char*);

base-commit: f661c0bb6371f355966a67b5ce71398e80792948
-- 
2.39.1


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2023-02-07 16:48 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-02-07 16:48 [pushed] doc: Update -fchar8_t documentation Marek Polacek

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).