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

Re: Broken syntax in vim.vim

Expand Messages
  • Charles Campbell
    ... Not sure what you want here. I usually interpret re in a vim context as meaning regular expression . Regards, C Campbell -- -- You received this
    Message 1 of 18 , Jun 26, 2013
    • 0 Attachment
      Yasuhiro MATSUMOTO wrote:
      > What value of your 're'?
      >
      Not sure what you want here. I usually interpret 're' in a vim context
      as meaning "regular expression".

      Regards,
      C Campbell

      --
      --
      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.
    • Yukihiro Nakadaira
      On Thu, Jun 27, 2013 at 12:38 AM, Charles Campbell
      Message 2 of 18 , Jun 26, 2013
      • 0 Attachment
        On Thu, Jun 27, 2013 at 12:38 AM, Charles Campbell <Charles.E.Campbell@...> wrote:
        Yukihiro Nakadaira wrote:

        On Wed, Jun 26, 2013 at 11:31 PM, Charles Campbell <Charles.E.Campbell@... <mailto:Charles.E.Campbell@nasa.gov>> wrote:

            I tried it again with simple.vimrc:

              set nocp
              syn on


        ":filetype plugin on" is also required to reproduce.
        ftplugin/vim.vim executes ":set iskeyword+=:"

        I tried the patch and it seems not fix that strange highlighting.

        I just did a pull from the Merc repository; the system ftplugin/vim.vim I got from it does not have set isk+=: in it.  Is this your own change?  Anyway, it seems that that's your problem.

        It is actually "setlocal isk+=:".


        --
        Yukihiro Nakadaira - yukihiro.nakadaira@...

        --
        --
        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.
         
         
      • Ingo Karkat
        ... The runtime update of Vim 7.3.488 (changeset 2cfb68fa26cd) adds : to iskeyword ; ostensibly To make syntax highlighting of vimVar s work correctly .
        Message 3 of 18 , Jun 26, 2013
        • 0 Attachment
          On 26-Jun-2013 17:38 +0200, Charles Campbell wrote:

          > Yukihiro Nakadaira wrote:
          >> On Wed, Jun 26, 2013 at 11:31 PM, Charles Campbell
          >> <Charles.E.Campbell@... <mailto:Charles.E.Campbell@...>> wrote:
          >>
          >> I tried it again with simple.vimrc:
          >>
          >> set nocp
          >> syn on
          >>
          >>
          >> ":filetype plugin on" is also required to reproduce.
          >> ftplugin/vim.vim executes ":set iskeyword+=:"
          >>
          >> I tried the patch and it seems not fix that strange highlighting.
          >>
          > I just did a pull from the Merc repository; the system ftplugin/vim.vim
          > I got from it does not have set isk+=: in it. Is this your own change?
          > Anyway, it seems that that's your problem.

          The runtime update of Vim 7.3.488 (changeset 2cfb68fa26cd) adds ":" to
          'iskeyword'; ostensibly "To make syntax highlighting of 'vimVar's work
          correctly". Since you, Charles, maintain the Vimscript syntax, I'd
          thought this actually came from you. (I had earlier complained about the
          intransparent and infrequent change process of runtime files in
          Mercurial; this is one instance where it hurts.)

          I'd like to object against this change, not just because of the current
          issue, but this also breaks tag jumping, because ctags puts functions
          without the scope prefix into the tags database. (And this is better,
          because prefixes are sometimes optional, and <SID> and s: are equivalent.)

          Therefore, Charles, can't you make "vimVar's work correctly" without
          adding ":" to 'iskeyword', and send a corresponding patch (for both
          syntax/vim.vim and ftplugin/vim.vim) to Bram?! That would solve both the
          broken syntax and the broken tag jumps.

          -- regards, ingo

          --
          --
          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.
        • Yukihiro Nakadaira
          On Thu, Jun 27, 2013 at 12:50 AM, Yukihiro Nakadaira
          Message 4 of 18 , Jun 26, 2013
          • 0 Attachment
            On Thu, Jun 27, 2013 at 12:50 AM, Yukihiro Nakadaira <yukihiro.nakadaira@...> wrote:
            On Thu, Jun 27, 2013 at 12:38 AM, Charles Campbell <Charles.E.Campbell@...> wrote:
            Yukihiro Nakadaira wrote:

            On Wed, Jun 26, 2013 at 11:31 PM, Charles Campbell <Charles.E.Campbell@... <mailto:Charles.E.Campbell@nasa.gov>> wrote:

                I tried it again with simple.vimrc:

                  set nocp
                  syn on


            ":filetype plugin on" is also required to reproduce.
            ftplugin/vim.vim executes ":set iskeyword+=:"

            I tried the patch and it seems not fix that strange highlighting.

            I just did a pull from the Merc repository; the system ftplugin/vim.vim I got from it does not have set isk+=: in it.  Is this your own change?  Anyway, it seems that that's your problem.

            It is actually "setlocal isk+=:".

            Sorry, "set isk+=:" is not essential to reproduce.
            "g:indent_guides_enable_on_vim_startup" is not highlighted as "vimVar" anyway.

            --
            Yukihiro Nakadaira - yukihiro.nakadaira@...

            --
            --
            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.
             
             
          • ZyX
            ... I second the request and can add another reasons: - It breaks python
            Message 5 of 18 , Jun 26, 2013
            • 0 Attachment
              > The runtime update of Vim 7.3.488 (changeset 2cfb68fa26cd) adds ":" to
              > 'iskeyword'; ostensibly "To make syntax highlighting of 'vimVar's work
              > correctly". Since you, Charles, maintain the Vimscript syntax, I'd
              > thought this actually came from you. (I had earlier complained about the
              > intransparent and infrequent change process of runtime files in
              > Mercurial; this is one instance where it hurts.)
              >
              >
              >
              > I'd like to object against this change, not just because of the current
              > issue, but this also breaks tag jumping, because ctags puts functions
              > without the scope prefix into the tags database. (And this is better,
              > because prefixes are sometimes optional, and <SID> and s: are equivalent.)
              >
              > Therefore, Charles, can't you make "vimVar's work correctly" without
              > adding ":" to 'iskeyword', and send a corresponding patch (for both
              > syntax/vim.vim and ftplugin/vim.vim) to Bram?! That would solve both the
              > broken syntax and the broken tag jumps.

              I second the request and can add another reasons:

              - It breaks python << EOF highlighting: `try:`/`else:` and so on is too common in python code.
              - It breaks using `*` for searching for function argument (in function definition there are no `a:`).
              - It breaks completion for functions with unique argument names (for the same reason) and completion for standard names (e.g. with consistent coding style there may be `l:repository` (`repository`) and `a:repository` at the same time).
              - It breaks expectations of how searching works: if I want to find some word in comment using `\<works\>` I definitely not expect that `works:` in this sentence is not matched. I also would not expect searching for `\<works:\>` if I press `*` on `works:` in this sentence. It is hard to keep different habits for different filetypes. `-` in `isk` in zsh files is already too bad, do not make it worse by adding third filetype to a list.

              --
              --
              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.
            • Charles Campbell
              ... Sounds like nasty stuff. Two problems: 1. There is no isk+=: in syntax/vim.vim v7.3-25 2. My copy of ftplugin/vim.vim, which I don t maintain, also does
              Message 6 of 18 , Jun 26, 2013
              • 0 Attachment
                ZyX wrote:
                >> The runtime update of Vim 7.3.488 (changeset 2cfb68fa26cd) adds ":" to
                >> 'iskeyword'; ostensibly "To make syntax highlighting of 'vimVar's work
                >> correctly". Since you, Charles, maintain the Vimscript syntax, I'd
                >> thought this actually came from you. (I had earlier complained about the
                >> intransparent and infrequent change process of runtime files in
                >> Mercurial; this is one instance where it hurts.)
                >>
                >>
                >>
                >> I'd like to object against this change, not just because of the current
                >> issue, but this also breaks tag jumping, because ctags puts functions
                >> without the scope prefix into the tags database. (And this is better,
                >> because prefixes are sometimes optional, and <SID> and s: are equivalent.)
                >>
                >> Therefore, Charles, can't you make "vimVar's work correctly" without
                >> adding ":" to 'iskeyword', and send a corresponding patch (for both
                >> syntax/vim.vim and ftplugin/vim.vim) to Bram?! That would solve both the
                >> broken syntax and the broken tag jumps.
                > I second the request and can add another reasons:
                >
                > - It breaks python << EOF highlighting: `try:`/`else:` and so on is too common in python code.
                > - It breaks using `*` for searching for function argument (in function definition there are no `a:`).
                > - It breaks completion for functions with unique argument names (for the same reason) and completion for standard names (e.g. with consistent coding style there may be `l:repository` (`repository`) and `a:repository` at the same time).
                > - It breaks expectations of how searching works: if I want to find some word in comment using `\<works\>` I definitely not expect that `works:` in this sentence is not matched. I also would not expect searching for `\<works:\>` if I press `*` on `works:` in this sentence. It is hard to keep different habits for different filetypes. `-` in `isk` in zsh files is already too bad, do not make it worse by adding third filetype to a list.
                >
                Sounds like nasty stuff. Two problems:

                1. There is no isk+=: in syntax/vim.vim v7.3-25
                2. My copy of ftplugin/vim.vim, which I don't maintain, also does not
                have isk+=: in it.

                Regards,
                C Campbell

                --
                --
                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.
              • Bram Moolenaar
                ... Right. I don t know how this got there. If it really is for syntax highlighting it should be in the syntax plugin, not the ftplugin. In case of doubt I
                Message 7 of 18 , Jun 26, 2013
                • 0 Attachment
                  Charles Campbell wrote:

                  > ZyX wrote:
                  > >> The runtime update of Vim 7.3.488 (changeset 2cfb68fa26cd) adds ":" to
                  > >> 'iskeyword'; ostensibly "To make syntax highlighting of 'vimVar's work
                  > >> correctly". Since you, Charles, maintain the Vimscript syntax, I'd
                  > >> thought this actually came from you. (I had earlier complained about the
                  > >> intransparent and infrequent change process of runtime files in
                  > >> Mercurial; this is one instance where it hurts.)
                  > >>
                  > >>
                  > >>
                  > >> I'd like to object against this change, not just because of the current
                  > >> issue, but this also breaks tag jumping, because ctags puts functions
                  > >> without the scope prefix into the tags database. (And this is better,
                  > >> because prefixes are sometimes optional, and <SID> and s: are equivalent.)
                  > >>
                  > >> Therefore, Charles, can't you make "vimVar's work correctly" without
                  > >> adding ":" to 'iskeyword', and send a corresponding patch (for both
                  > >> syntax/vim.vim and ftplugin/vim.vim) to Bram?! That would solve both the
                  > >> broken syntax and the broken tag jumps.
                  > > I second the request and can add another reasons:
                  > >
                  > > - It breaks python << EOF highlighting: `try:`/`else:` and so on is
                  > > too common in python code.
                  > > - It breaks using `*` for searching for function argument (in
                  > > function definition there are no `a:`).
                  > > - It breaks completion for functions with unique argument names (for
                  > > the same reason) and completion for standard names (e.g. with
                  > > consistent coding style there may be `l:repository` (`repository`)
                  > > and `a:repository` at the same time).
                  > > - It breaks expectations of how searching works: if I want to find
                  > > some word in comment using `\<works\>` I definitely not expect that
                  > > `works:` in this sentence is not matched. I also would not expect
                  > > searching for `\<works:\>` if I press `*` on `works:` in this
                  > > sentence. It is hard to keep different habits for different
                  > > filetypes. `-` in `isk` in zsh files is already too bad, do not make
                  > > it worse by adding third filetype to a list.
                  > >
                  > Sounds like nasty stuff. Two problems:
                  >
                  > 1. There is no isk+=: in syntax/vim.vim v7.3-25
                  > 2. My copy of ftplugin/vim.vim, which I don't maintain, also does not
                  > have isk+=: in it.

                  Right. I don't know how this got there. If it really is for syntax
                  highlighting it should be in the syntax plugin, not the ftplugin.

                  In case of doubt I prefer to leave 'iskeyword' alone.

                  --
                  FATHER: Make sure the Prince doesn't leave this room until I come and
                  get him.
                  FIRST GUARD: Not ... to leave the room ... even if you come and get him.
                  FATHER: No. Until I come and get him.
                  SECOND GUARD: Hic.
                  "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD

                  /// Bram Moolenaar -- Bram@... -- 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.
                • Manuel Ortega
                  On Wed, Jun 26, 2013 at 1:09 PM, Charles Campbell
                  Message 8 of 18 , Jun 26, 2013
                  • 0 Attachment
                    On Wed, Jun 26, 2013 at 1:09 PM, Charles Campbell <Charles.E.Campbell@...> wrote:


                    Sounds like nasty stuff.  Two problems:

                    1. There is no isk+=: in syntax/vim.vim v7.3-25

                    Not here either.

                     
                    2. My copy of ftplugin/vim.vim, which I don't maintain, also does not have isk+=: in it.


                    But mine does (line 26: setlocal isk+=:), and I don't fiddle with mine either.

                    -Manny

                    --
                    --
                    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.
                     
                     
                  • mattn
                    https://gist.github.com/mattn/5865363 I fixed patch. Could you try this again? -- -- You received this message from the vim_dev maillist. Do not top-post!
                    Message 9 of 18 , Jun 26, 2013
                    • 0 Attachment
                      https://gist.github.com/mattn/5865363

                      I fixed patch.
                      Could you try this again?

                      --
                      --
                      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.
                    • mattn
                      ... I found a bug. a, bs/foo/bar/g is broken. Fixed this. https://gist.github.com/mattn/5865363 http://go-gyazo.appspot.com/bf30bee5ac94c3ca.png -- -- You
                      Message 10 of 18 , Jun 26, 2013
                      • 0 Attachment
                        On Thursday, June 27, 2013 2:36:36 PM UTC+9, mattn wrote:
                        > https://gist.github.com/mattn/5865363
                        >
                        > I fixed patch.
                        > Could you try this again?

                        I found a bug.

                        'a,'bs/foo/bar/g is broken.

                        Fixed this.

                        https://gist.github.com/mattn/5865363

                        http://go-gyazo.appspot.com/bf30bee5ac94c3ca.png

                        --
                        --
                        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.
                      • Ingo Karkat
                        ... While I respect your decision to keep the dev process as it currently works for you, and while I don t want to resurrect the old discussion
                        Message 11 of 18 , Jun 26, 2013
                        • 0 Attachment
                          On 26-Jun-2013 19:18 +0200, Bram Moolenaar wrote:

                          > [44 lines deleted]
                          >
                          > Right. I don't know how this got there. If it really is for syntax
                          > highlighting it should be in the syntax plugin, not the ftplugin.

                          While I respect your decision to keep the dev process as it currently
                          works for you, and while I don't want to resurrect the old discussion
                          (https://groups.google.com/d/msg/vim_dev/9tggyPAX7sY/Hcz0TSkZpPIJ), I
                          can't stop myself from mentioning that with atomic commits of runtime
                          changes (like you do for source code patches), there would be a much
                          better chance of determining what this change was about. (Assuming you
                          had written a suitable commit message.)

                          Come on, you could just give it a try and do slightly more fine-grained
                          commits of runtime updates in the future. If it's too much effort, just
                          revert back to the bulky updates (occasionally).

                          > In case of doubt I prefer to leave 'iskeyword' alone.

                          Alright, so you're going to remove "isk+=:", but keep "isk+=#" (which is
                          undisputedly beneficial) in ftplugin/vim.vim?! Thanks!

                          -- regards, ingo

                          --
                          --
                          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.