On 27/03/2008, Nikolai Weibull <[EMAIL PROTECTED]> wrote: > On Thu, Mar 27, 2008 at 1:16 PM, Antony Scriven > <[EMAIL PROTECTED]> wrote: > > > On 27/03/2008, Ben Schmidt <[EMAIL PROTECTED]> wrote: > > > > Antony Scriven wrote: > > > > > I'd prefer the longest match rather than the > > > > first alternative (as specified by POSIX) > > > > An interesting twist. Can you clarify which behaviour > > > POSIX specifies (your sentence above is ambiguous)? > > > You're right, sorry. POSIX specifies longest match. > > /left-most/ longest. Big difference.
I thought the `left-most' part was a given and we were discussing which of the alternatives would be subsequently picked; sorry if I was misleading. In this case POSIX specifies that the alternative which gives the longest overall match is picked, whereas backtracking implementations (like that in Vim) are usually designed to pick the first alternative that gives an overall match, even if a different choice would give a longer overall match. I know you know this already, I'm just trying to be clear! Now, I'm still not sure I've managed to do that, so please rephrase my explanation for me if you think it is necessary :-) --Antony --~--~---------~--~----~------------~-------~--~----~ You received this message from the "vim_dev" maillist. For more information, visit http://www.vim.org/maillist.php -~----------~----~----~----~------~----~------~--~---