On Wed, Feb 06, 2013 at 04:06:01PM +0100, Bram Moolenaar wrote:
> The syntax file is using the old style HiLink command. You can just
> use "hi def".
Gladly. I believe this was simply cargo-culted from existing syntax
files. Should I also remove the
if version < 600
syntax clear
…
at the top of the file, since the apparent reason for HiLink is
backwards compatibility?
> The syntax file changes the 'iskeyword' option. This has many side
> effects. Can you use "syn match" instead of "syn keyword" and avoid
> setting 'iskeyword'?
The Clojure language, being a Lisp, accepts many non-word characters in
its identifiers¹, so the purpose of augmenting 'iskeyword' is not just
for the benefit of the `syntax keyword` definitions.
The existing suite of Vim plugins that are designed to work with these
runtime files actually assume these additions to 'iskeyword' in order to
find word boundaries, so removing this would cause breakage, and then
plugin authors would simply augment 'iskeyword' themselves.
However, I can see now that setting 'iskeyword' in the syntax file
instead of the ftplugin is problematic because the setting becomes local
to the buffer and not to the filetype, which will cause confusion if a
user changes filetypes for a buffer.
Do you think it is an acceptable compromise if I change the `syntax
keyword` definitions to `syntax match` and move the 'iskeyword' setting
to the ftplugin?
Thank you for your attention.
Sung Pae
¹ In Clojure, word boundaries are defined by whitespace, brackets, and
metacharacters for the Lisp reader.
For example, these functions and variables are in the standard lib:
*command-line-args*
list*
->
cond->>
zero?
set!
These non-word characters, along with a few others, are very widely
used as identifiers in the Clojure community
--
--
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.