#elsif

Joern Rennecke amylaar@cygnus.co.uk
Thu Apr 9 17:44:00 GMT 1998


> I assume that you do not want to make a special case for `elsif' only.
> (That would be odd; it wouldn't catch other misspellings like `elseif'.)

Yes, if we warn for elsif, we should have a like warning for elseif.
Both are misspellings of elif that mirror a programming language and
might thus be mistaken for the real thing.  They are special because they
are supposedly meant to end the commenting out.  If there were likely
misspellings of #endif that could be mistaken for the real thing doe to
the similarity with another language (hmmm... maybe #fi would qualify?),
that these should also be warned about.

The warning for such a specific test should not just be something
vanilla like unrecognized #-directive, since that could make people
think we warned about all unrecognized directives.
It should somehow point out the assumed error.



More information about the Gcc mailing list