On Fri Jul 7 16:56:13 2023 +0000, Alexandre Julliard wrote:
Great! Please start by building a list of all the features that would be interesting to know about, and we can then fill in the status. The why is usually "because someone reported breakage". You could make it point to the corresponding bug report if you can find it.
Just to help out a bit, here's some things I'm aware of:
* MSVC used to break on designated initializers, although newer versions don't, and patches using them have basically been committed since that fact was pointed out: https://www.winehq.org/mailman3/hyperkitty/list/wine-devel@winehq.org/messag...
* gcc 4.3.4 allows nameless unions, but can't parse them in designated initializers: https://bugs.winehq.org/show_bug.cgi?id=50378
* I was able to find a mention of very old versions of GCC that don't support nameless unions: https://www.winehq.org/mailman3/hyperkitty/list/wine-devel@winehq.org/messag...
* For 0-length array members, I found this: https://www.winehq.org/mailman3/hyperkitty/list/wine-devel@winehq.org/messag...
* I do not know of any compiler that forbids C++ comments. Granted, I haven't been contributing to Wine for nearly long enough to be aware of these things, but I've only seen them mentioned under vague terms like "we don't use them in Wine". Even if there isn't a compiler that cares, it's not clear to me whether they're proscribed because of taste (I think I've seen some subsystem maintainers express that, but I can't remember where), or if they'd be perfectly acceptable if anyone cared to use them.
Alexandre, I think this is one of the points Alex is confused about, and is trying to ask for a ruling on. If you feel that this is too minor an issue to give a formal ruling on, fine, I'd just like to make that clarification lest anyone else get too much more frustrated.
* Declaration-after-statement falls into pretty much the same category. We specifically have a warning on for this, so it's pretty clearly proscribed, but I'm not sure if it's done for compatibility reasons or aesthetic ones (again, I've seen some people express a strong aesthetic preference for this, and I'm inclined to agree—if only because I've become used to looking towards the top of a block for declarations). The warning was added back in 2005 (f8cb48b515), but I wasn't able to easily find any inciting incidents.
* Initial declarations in 'for' loops are a special case of the above. We used to regularly get bug reports for this (e.g. https://bugs.winehq.org/show_bug.cgi?id=47262) but I think that may just be because old versions of gcc defaulted to -std=c89, and are actually fine with it as long as we set -std=c99, which we do since 0aa31b735cc. Despite disliking declaration-after-statement in the general case, I'm actually inclined to think that declarations in for loops are desirable—that helps the programmer ensure they don't accidentally use a loop iterator outside of the loop's scope. Others might disagree, though; I'm not sure whether I've heard an opinion on the aesthetics of this one.
* I don't think I've seen typedef redefinitions come up before.