[comp.std.c] Are Stringize and Token Pasting operators in the Std?

art@dinorah.wustl.edu (Arthur B. Smith) (02/28/90)

Here's a quick question for someone with a copy of the Standard.

According to both K&R2 and Mark Williams Company's "ANSI C, A Lexical
Guide" (A very useful book, BTW), the stringize (#) and token pasting
(##) operators are part of the standard (sections 3.8.3.2 and 3.8.3.3,
respectively).  Unfortunately of five C compilers (with varying levels
of (real and imagined) ANSI compliance) I have available, only one
implements both operators, and another implements only token pasting.

So are these in ANSI C (sections 3.8.3.2 and 3.8.3.3)?

Please e-mail to me.  I will post the answer if IMWTK.

    TIA!
    art smith
(art@dinorah.wustl.edu   -or-   ...!uunet!wucs1!dinorah!art)

henry@utzoo.uucp (Henry Spencer) (03/02/90)

In article <1990Feb28.145611.15636@dinorah.wustl.edu> art@dinorah.wustl.edu (Arthur B. Smith) writes:
>Here's a quick question for someone with a copy of the Standard.
>According to [books], the stringize (#) and token pasting
>(##) operators are part of the standard...  of five C compilers (with
>varying levels of (real and imagined) ANSI compliance) ..., only one
>implements both operators, and another implements only token pasting...
>So are these in ANSI C ...?

Yes.  However, *nobody* has a copy of the Standard yet, except for the
production people at ANSI, and many "ANSI compliant" compilers comply
with some early draft that bears only limited resemblance to the final
Standard.
-- 
MSDOS, abbrev:  Maybe SomeDay |     Henry Spencer at U of Toronto Zoology
an Operating System.          | uunet!attcan!utzoo!henry henry@zoo.toronto.edu