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

Re: [patch] Fix matching braces separated by commented braces

Expand Messages
  • Gary Johnson
    ... You can also get this modified behavior by enabling the matchit.vim plugin ($VIMRUNTIME/macros/matchit.vim) and enabling syntax highlighting. Regards, Gary
    Message 1 of 3 , Jan 2, 2013
    • 0 Attachment
      On 2013-01-02, GM wrote:
      > Greetings vim-dev,
      >
      > I have a patch I would like to submit to fix a bug in vim.
      >
      >
      >
      > Description of the problem and the patch:
      > ===========================
      >
      > In the code below, place the cursor over the brace { on the end of the
      > first line.
      > Press % to jump the cursor to the matching brace.
      > The cursor jumps to the first brace inside the comment.
      >
      > This patch modifies that behavior so that the cursor jumps to the
      > matching brace on the final line.
      >
      > for( $x = 0; $x < 10; $x++ ) { // Place the cursor on this brace.
      > if( $x == 4 ) {
      > echo "x is equal to 4!\n";
      > }
      > // } else { echo "x is not equal to 4... =(\n"; }
      > } // It should jump to this brace, but it does not. This patch
      > corrects this behavior.

      You can also get this modified behavior by enabling the matchit.vim
      plugin ($VIMRUNTIME/macros/matchit.vim) and enabling syntax
      highlighting.

      Regards,
      Gary

      --
      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
    Your message has been successfully submitted and would be delivered to recipients shortly.