To reproduce:

    $ cat >test.sh <<EOF
    #!/bin/sh
    myfunc () (
          set -e
          for arg; do
            test -e "$arg"
          done
          if [ $# -gt 0 ]; then exit 1; fi
      # no 'comment
    )
    $ vim -u NONE -c ':syntax on' test.sh

Problems that appear inside subshell () or command substition $():
- the hash # does not start a comment (in the example the single quote
  starts a string)
- the keywords for, if and set are not recognized (furthermore in the
  example the semicolons are highlighted) but exit etc. is
- there might be other issues since it seems that the code inside a
  sub-shell is processed peculiarly


This bug is found in Debian sid and Debian stable:

VIM - Vi IMproved 7.4 (2013 Aug 10, compiled Feb  3 2014 00:39:14)
Included patches: 1-161
Modified by [email protected]

VIM - Vi IMproved 7.3 (2010 Aug 15, compiled Feb 10 2013 02:28:47)
Included patches: 1-547
Modified by [email protected]

-- 
-- 
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 [email protected].
For more options, visit https://groups.google.com/groups/opt_out.

Raspunde prin e-mail lui