https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117156

            Bug ID: 117156
           Summary: not applied option “-Wchanges-meaning”
           Product: gcc
           Version: 14.2.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: ing.russomauro at gmail dot com
  Target Milestone: ---

The option “-Wchanges-meaning” presented in:
https://developers.redhat.com/articles/2023/06/21/new-c-features-gcc-13

does not work on the same code shown there to describe the option:

struct A {};
struct B { A a; struct A { }; }; // error, A changes meaning

The error is still raised even when the option “-Wchanges-meaning” is added.

Please, see https://godbolt.org/z/9E4rqGqhz

The same applies to 13.1, 13.2, 13.3, 14.1 versions, whereas 12.4 (or earlier)
does not recognise the option.

Only the option "-fpermissive" still downgrade toward a warning, with or
without “-Wchanges-meaning”.

Reply via email to