On Thursday 30 May 2013 00:22:01 Oleksii Taran wrote:
> 28.05.13 11:00, Schrober написав(ла):
> > [this is a resent because the mail was dropped somewhere before reaching
> > the mailing list]
> > 
> > Hi,
> > 
> > I wanted to use re2c to implement some matching like functionality in a
> > buffer which is defined by its location in memory and length (so, the
> > length is not detectable by some symbol after the content of the buffer).
[...]
> 
> Try to disable yyfill, since for fixed size matched strings it is pretty
> much useless

There are not fixed size strings, but buffers with a defined length during the 
matching phase. So they have no end marker in form a a special symbol. The 
example used const strings with a \0-Symbol just for the sake of symplicity.

What I would have expected is a fill with n == with the minimum length for a 
possible match (aka. minimum length for an accepted match or in case of a half 
matched string -> minimum length required to have a match from this position, 
including the minimum length to finish the partial match). Doing it with the 
longest fixed substring seems extremely wrong to me. Lets assume it is used to 
lex a language consisting of two symbols represented by the strings 
"bbbbbbbbbbbb" and "a". The input from an arbitary source which needs refill 
is now "bbbbbbbbbbbba" - why should the a not be accepted by a lexer generated 
by re2c just because there is an extreme long symbol "bbbbbbbbbbbb"?
-- 
Franz Schrober

------------------------------------------------------------------------------
Introducing AppDynamics Lite, a free troubleshooting tool for Java/.NET
Get 100% visibility into your production application - at no cost.
Code-level diagnostics for performance bottlenecks with <2% overhead
Download for free and get started troubleshooting in minutes.
http://p.sf.net/sfu/appdyn_d2d_ap1
_______________________________________________
Re2c-general mailing list
Re2c-general@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/re2c-general

Reply via email to