Re: [PHP4BETA] re2c ?
| From: | Sascha Schumann | Date: | Mon, 20 Sep 1999 12:46:01 +0000 |
| Subject: | Re: [PHP4BETA] re2c ? | ||
| References: | 1 2 | Groups: | php.version4 |
| Request: | Send a blank email to php-version4+get-4663@lists.php.net to get a copy of this message | ||
On Mon, Sep 20, 1999 at 01:23:36PM +0200, Zeev Suraski wrote:
>
> Any reason we don't use flex for the URL scanner? flex seems
> to generate much cleaner code, it's much more standard than
> re2c, and we already rely on it...?
Two reasons
- speed. re2c generally generates faster code. This was
important in this context, since the whole output of
scripts needs to be reparsed.
- flexibility of the input model. re2c does not make any
assumptions in this area. lex makes terrible assumptions,
leading to incompatibilities between various lex
implementations, if you want to use a string as input
rather than real IO. (This scanner is also used for
another project which can not depend on flex..)
In conclusion, don't touch(1) *.re and everything works fine.
--
Regards,
Sascha Schumann
Consultant