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

Eric Gallager <egallager at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |egallager at gcc dot gnu.org

--- Comment #3 from Eric Gallager <egallager at gcc dot gnu.org> ---
(In reply to Alexander Regueiro from comment #0)
> Const-correctness often becomes very difficult for large and complex
> programs, due to the finicky nature in which it is implemented. (In my view,
> the fact that it qualifies types and not values is big design mistake.) Many
> C (and C++) programmers do not like to have to worry about const-correctness
> at all, as they feel the troubles outweigh the benefits.
> 
> At the moment, for the compiler to effectively ignore const qualifiers, I
> have to do something that is overkill – namely, specify the
> `-Wno-incompatible-pointer-types` and
> `-Wno-incompatible-pointer-types-discards-qualifiers` options to the driver.

Note that the latter is a clang-only option.

> This is less than ideal, since the former removes some much more useful
> warnings that have nothing to do with the const qualifiers.
> 
> Could we implement a feature that just ignores all const qualifiers when
> compiling?

Reply via email to