Loading ...
Sorry, an error occurred while loading the content.

Re: [BUG] re=1 and re=2 differ with branches

Expand Messages
  • Zulox4
    Hello! I test using the files attached in Vim 7.4.27 searching in the buffer content: klocks (1.0, 20130715) Command Line Lock Keys ...
    Message 1 of 9 , Sep 17, 2013
    • 0 Attachment
      Hello! I test using the files attached in Vim 7.4.27 searching in the buffer content:
      klocks (1.0, 20130715) Command Line Lock Keys

      1. For the command:
      :set hlsearch regexpengine=1
      /^\C[a-z]\+\ze \&\(\.exe\)\@<!

      the first word is selected.

      2. For the command
      :set hlsearch regexpengine=2
      /^\C[a-z]\+\ze \&\(\.exe\)\@<!

      the first letter of the line is selected.

      Best regards !

      On Tuesday, September 17, 2013 11:44:56 PM UTC+2, Bram Moolenaar wrote:
      > Axel Bender wrote:
      >
      >
      >
      > > The following search command with branches works differently depending
      >
      > > on which RE engine is chosen:
      >
      > >
      >
      > > ^\C[a-z]\+\ze \&\(\.exe\)\@<!
      >
      > >
      >
      > > With re=1 the whole first word is selected.
      >
      > > With re=2 only the first letter of the first word is selected.
      >
      > >
      >
      > > Test case included.
      >
      >
      >
      > What version of Vim, which patches did you include?
      >
      >
      >
      > --
      >
      > hundred-and-one symptoms of being an internet addict:
      >
      > 224. You set up your own Web page. You set up a Web page for each
      >
      > of your kids... and your pets.
      >
      >
      >
      > /// Bram Moolenaar -- B...@... -- http://www.Moolenaar.net \\\
      >
      > /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
      >
      > \\\ an exciting new programming language -- http://www.Zimbu.org ///
      >
      > \\\ help me help AIDS victims -- http://ICCF-Holland.org ///

      --
      --
      You received this message from the "vim_dev" maillist.
      Do not top-post! Type your reply below the text you are replying to.
      For more information, visit http://www.vim.org/maillist.php

      ---
      You received this message because you are subscribed to the Google Groups "vim_dev" group.
      To unsubscribe from this group and stop receiving emails from it, send an email to vim_dev+unsubscribe@....
      For more options, visit https://groups.google.com/groups/opt_out.
    • Axel Bender
      ... Sorry, I forgot to mention that: 7.4-27 on Windows 7 (64 bit) compiled with gcc 64 bit. -- -- You received this message from the vim_dev maillist. Do not
      Message 2 of 9 , Sep 18, 2013
      • 0 Attachment
        > What version of Vim, which patches did you include?

        Sorry, I forgot to mention that: 7.4-27 on Windows 7 (64 bit) compiled with gcc 64 bit.

        --
        --
        You received this message from the "vim_dev" maillist.
        Do not top-post! Type your reply below the text you are replying to.
        For more information, visit http://www.vim.org/maillist.php

        ---
        You received this message because you are subscribed to the Google Groups "vim_dev" group.
        To unsubscribe from this group and stop receiving emails from it, send an email to vim_dev+unsubscribe@....
        For more options, visit https://groups.google.com/groups/opt_out.
      • Axel Bender
        Addendum: There s an error in run ; it should read ...+ so re1.so ... (rsp. re2.so) in there. Sorry. -- -- You received this message from the vim_dev
        Message 3 of 9 , Sep 18, 2013
        • 0 Attachment
          Addendum: There's an error in "run"; it should read '...+"so re1.so" ...' (rsp. re2.so) in there. Sorry.

          --
          --
          You received this message from the "vim_dev" maillist.
          Do not top-post! Type your reply below the text you are replying to.
          For more information, visit http://www.vim.org/maillist.php

          ---
          You received this message because you are subscribed to the Google Groups "vim_dev" group.
          To unsubscribe from this group and stop receiving emails from it, send an email to vim_dev+unsubscribe@....
          For more options, visit https://groups.google.com/groups/opt_out.
        • Axel Bender
          Uploaded new case files... -- -- You received this message from the vim_dev maillist. Do not top-post! Type your reply below the text you are replying to.
          Message 4 of 9 , Sep 18, 2013
          • 0 Attachment
            Uploaded new case files...

            --
            --
            You received this message from the "vim_dev" maillist.
            Do not top-post! Type your reply below the text you are replying to.
            For more information, visit http://www.vim.org/maillist.php

            ---
            You received this message because you are subscribed to the Google Groups "vim_dev" group.
            To unsubscribe from this group and stop receiving emails from it, send an email to vim_dev+unsubscribe@....
            For more options, visit https://groups.google.com/groups/opt_out.
          • Christian Brabandt
            ... Would you mind using a different archive format? regards, Christian -- -- You received this message from the vim_dev maillist. Do not top-post! Type your
            Message 5 of 9 , Sep 18, 2013
            • 0 Attachment
              On Wed, September 18, 2013 09:27, Axel Bender wrote:
              > Uploaded new case files...

              Would you mind using a different archive format?

              regards,
              Christian

              --
              --
              You received this message from the "vim_dev" maillist.
              Do not top-post! Type your reply below the text you are replying to.
              For more information, visit http://www.vim.org/maillist.php

              ---
              You received this message because you are subscribed to the Google Groups "vim_dev" group.
              To unsubscribe from this group and stop receiving emails from it, send an email to vim_dev+unsubscribe@....
              For more options, visit https://groups.google.com/groups/opt_out.
            • Axel Bender
              @Christian, no I wouldn t ;-) Reuploaded as ZIP. -- -- You received this message from the vim_dev maillist. Do not top-post! Type your reply below the text
              Message 6 of 9 , Sep 18, 2013
              • 0 Attachment
                @Christian,

                no I wouldn't ;-)

                Reuploaded as ZIP.

                --
                --
                You received this message from the "vim_dev" maillist.
                Do not top-post! Type your reply below the text you are replying to.
                For more information, visit http://www.vim.org/maillist.php

                ---
                You received this message because you are subscribed to the Google Groups "vim_dev" group.
                To unsubscribe from this group and stop receiving emails from it, send an email to vim_dev+unsubscribe@....
                For more options, visit https://groups.google.com/groups/opt_out.
              • Vlad Irnov
                ... I think the following shows what happens (gvim7.4 on Windows). It s strange combination of ze, & and @
                Message 7 of 9 , Sep 18, 2013
                • 0 Attachment
                  On 9/17/13, Axel Bender <axel.bender@...> wrote:
                  > The following search command with branches works differently depending on
                  > which RE engine is chosen:
                  >
                  > ^\C[a-z]\+\ze \&\(\.exe\)\@<!
                  >
                  > With re=1 the whole first word is selected.
                  > With re=2 only the first letter of the first word is selected.
                  >
                  > Test case included.

                  I think the following shows what happens (gvim7.4 on Windows).
                  It's strange combination of \ze, \& and \@<! that makes finding the
                  end of match ambiguous.

                  :echo "'". matchstr('ABCD ', '\%#=1^ABCD\ze \&E\@<!') ."'"
                  :echo "'". matchstr('ABCD ', '\%#=2^ABCD\ze \&E\@<!') ."'"
                  :echo match('ABCD ', '\%#=1^ABCD\ze \&E\@<!')
                  :echo match('ABCD ', '\%#=2^ABCD\ze \&E\@<!')

                  'ABCD'
                  ''
                  0
                  0

                  --
                  --
                  You received this message from the "vim_dev" maillist.
                  Do not top-post! Type your reply below the text you are replying to.
                  For more information, visit http://www.vim.org/maillist.php

                  ---
                  You received this message because you are subscribed to the Google Groups "vim_dev" group.
                  To unsubscribe from this group and stop receiving emails from it, send an email to vim_dev+unsubscribe@....
                  For more options, visit https://groups.google.com/groups/opt_out.
                Your message has been successfully submitted and would be delivered to recipients shortly.