wpp: Fix expansion of macro bodies following the parsing of a numerical digit.

Rob Shearman robertshearman at gmail.com
Mon Jan 18 16:15:09 CST 2010


The current regular expression causes all letters and spaces (among
other characters) following the appearance of a digit to be classed as
a literal, including C identifiers which may need to be expanded.

The expression was intended to catch the remaining characters that
were not covered by the first two rules ([^a-zA-Z0-9'"#/\\\n]+ and
{cident}), but the [^'"#/\\\n] expression caught {cident} as well.
While one solution would have been just to catch the expression that
match [a-zA-Z0-9]* that don't match {cident}, i.e. [0-9][a-zA-Z0-9]*,
in the interests of avoiding unnecessary multiple LITERALs being
generated and then combined during parsing the expression also
includes the first expression, making it
[0-9][a-zA-Z0-9]*[^a-zA-Z0-9'"#/\\\n]*.
---
 libs/wpp/ppl.l |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-wpp-Fix-expansion-of-macro-bodies-following-the-pars.patch
Type: text/x-patch
Size: 737 bytes
Desc: not available
URL: <http://www.winehq.org/pipermail/wine-patches/attachments/20100118/1d014887/attachment.bin>


More information about the wine-patches mailing list