]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
c++: add deprecation notice for -fconcepts-ts
authorMarek Polacek <polacek@redhat.com>
Tue, 30 Jan 2024 22:11:34 +0000 (17:11 -0500)
committerMarek Polacek <polacek@redhat.com>
Wed, 31 Jan 2024 20:12:16 +0000 (15:12 -0500)
We plan to remove -fconcepts-ts in GCC 15 and thus remove the flag_concepts_ts
code.  This note is an admonishing reminder to convert the Concepts TS
code to C++20 Concepts.

gcc/c-family/ChangeLog:

* c-opts.cc (c_common_post_options): Add an inform saying that
-fconcepts-ts is deprecated and will be removed in GCC 15.

gcc/ChangeLog:

* doc/invoke.texi: Mention that -fconcepts-ts was deprecated in GCC 14.

gcc/c-family/c-opts.cc
gcc/doc/invoke.texi

index b38a1225ac43867eb8172006d115db93afdec9f8..b845aff2226fa34565eb000bc9e3806adc63c478 100644 (file)
@@ -1139,6 +1139,11 @@ c_common_post_options (const char **pfilename)
   if (cxx_dialect >= cxx20 || flag_concepts_ts)
     flag_concepts = 1;
 
+  /* -fconcepts-ts will be removed in GCC 15.  */
+  if (flag_concepts_ts)
+    inform (input_location, "%<-fconcepts-ts%> is deprecated and will be "
+           "removed in GCC 15; please convert your code to C++20 concepts");
+
   /* -fimmediate-escalation has no effect when immediate functions are not
      supported.  */
   if (flag_immediate_escalation && cxx_dialect < cxx20)
index eb931b984e8f055538815822dcd9a7cacc26cc3c..ca2c0e90452d627c10a2145108e7bddcc9eac9de 100644 (file)
@@ -3204,7 +3204,9 @@ the language standard, so @option{-fconcepts} defaults to on.
 Some constructs that were allowed by the earlier C++ Extensions for
 Concepts Technical Specification, ISO 19217 (2015), but didn't make it
 into the standard, can additionally be enabled by
-@option{-fconcepts-ts}.
+@option{-fconcepts-ts}.  The option @option{-fconcepts-ts} was deprecated
+in GCC 14 and may be removed in GCC 15; users are expected to convert
+their code to C++20 concepts.
 
 @opindex fconstexpr-depth
 @item -fconstexpr-depth=@var{n}