Prof. Abimbola A. Olowofoyeku wrote:
On 29 May 2004 at 9:01, Grant Jacobs wrote:
[...]
- I've been warned about using underscores at the end of
identifiers. Obviously I can rename them, but there is a reason for this naming. Does this really do any harm? I can understand issues with underscores at the start of identifiers, but at the end?
Just pass "-Wno-underscore".
Ta, missed that one when scanning the options.
I have often wondered myself what the warnings about underscores are for. Can someone please explain why they are considered worthy of warnings?
AFAIKS the warning was introduced many years ago, so I can not say about original motivation. However, my rationale is: leading or trailing underscores (and double underscore inside) are forbiden in ISO 10206. Since such underscores are quite easy to avoid in new code the warning seem justified. And for legacy code `-Wno-underscore' gets rid of the warning.