On 13.02.2020 18:00, Valery Ushakov wrote: > Arguably, if the tool you use is broken, you shouln't be mutilating > the source code just to shut that tool up. The introduced changes were good, even if GCC would be silent. It is far from mutilating. As an alternative option we can disable warnings but this is in my opinion much worse in this case than potentially overlooking real problems in a 4000+ line file. On the opposite side of this if this camp is MUSL. I used chunks of the MUSL code and it had poor results. There is a strict policy to avoid casts unless absolutely needed and if they are needed this tends to be in as obscure way as possible (like adding U attribute to one of the arguments in an expression). This resulted in unmaintainable code and very difficult situation to guess whether code semantics is broken or buggy. For purists, MUSL is not mutilated at all so people wanting this style are informed where to find it now. Today I prefer explicit casts (after the MUSL lesson) even if unnecessary than implicit promotion. I'm not alone in here as the promotion rules are considered by many people as the major flaw in C. Everybody agrees that GCC was picky in that case and not mandatory from a strict language point of view. Repeatedly informing that the tool (GCC) is broken did not solve any issue. It would be finally better to see someone fixing GCC rather than informing other GCC users about it.
Attachment:
signature.asc
Description: OpenPGP digital signature