lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


> > Just an implementation detail, but I think it would be advisable to tie it
> > to the start of the string, making the case of failed matches much quicker;
> > I believe it produces the same results:
> > print(s:find('^.*()'..w))
> 
> Excellent point!

Also, you can use s:match instead of s:find (and then you have only the
position as a result).

-- Roberto