|Flex regular expression problem email@example.com (pmatos) (2005-08-21)|
|Re: Flex regular expression problem Meyer-Eltz@t-online.de (Detlef Meyer-Eltz) (2005-08-24)|
|Re: Flex regular expression problem firstname.lastname@example.org (Laurence Finston) (2005-08-24)|
|Re: Flex regular expression problem email@example.com (Paolo Bonzini) (2005-08-31)|
|From:||Laurence Finston <firstname.lastname@example.org>|
|Date:||24 Aug 2005 18:26:30 -0400|
|Posted-Date:||24 Aug 2005 18:26:30 EDT|
> but it never works as I expect. Any ideas?
You could use a start condition for strings. The scanner should enter it
when it scans the first double quote character and collect all characters
up to the closing double quote, at which point it should leave the start
condition. I would also implement a way of quoting
double quote characters, so that "\"" would be interpreted as a string
containing a double quote character, and not a string containing a
backslash followed by an opening double quote. You could also implement
special handling for other characters or sequences of characters.
Return to the
Search the comp.compilers archives again.