Re: [sv-bc] white space at the end of macro text

From: Greg Jaxon <Greg.Jaxon_at_.....>
Date: Mon Feb 13 2006 - 15:03:32 PST
Steven Sharp wrote:
> Since SystemVerilog (i.e. IEEE Std 1800) has added quote-creation and
> token-pasting operations, it needs to specify the white space treatment
> for macro expansion more precisely.

The ANSI C preprocessor is an example standard worth reviewing as these
SV features are clarified.  X3J11's working drafts are available online at:
http://std.dkuug.dk/JTC1/SC22/WG14/www/docs/n843.pdf

Relevant sections are: 5.1.1.2
                        6.4
                        6.10.3

It appears that leading and trailing whitespace is trimmed from
preprocessor token sequences.  Treatment of embedded whitespace
is not standardized except that /*comments*/ turn into a single
space.  So, in conforming programs, string literals produced
by the preprocessor are not character-for-character portable.

Greg Jaxon
Received on Mon Feb 13 15:08:39 2006

This archive was generated by hypermail 2.1.8 : Mon Feb 13 2006 - 15:09:38 PST