|
 |
Darren New <dne### [at] san rr com> wrote:
> Warp wrote:
> > These are the same people who will not bother fixing their broken
> > C preprocessor even though they know it's broken (they have officially
> > stated that they won't fix it anytime soon).
> BTW, I don't think it's likely a matter of "won't bother" as much as it is
> "have decided backwards-bug-compatibility is more important to our business
> than being correct." There are a fair number of bugs in various MS products
> that don't get fixed because people are depending upon the buggy behavior.
> Remind me again what the problem is?
Basically, preprocessor macro expansion should never create new tokens
unless the token pasting operator (##) is explicitly used to do so. However,
Microsoft's C preprocessor doesn't take this into account at all.
For example, if you have:
#define STAR *
then /STAR should not start a comment. However, it does start a comment in
MSVC. Likewise if you have:
#define X -1
#define Y -X
then instantiating Y should not be an attempt to decrement a literal.
However, in MSVC it is.
--
- Warp
Post a reply to this message
|
 |