Hi,

On Wed, Jun 19, 2019 at 6:47 AM Bram Moolenaar
<[email protected]> wrote:
>
>
> > > I also use Javascript/Typescript regularly, which is why I know the
> > > backtick is hard to recognize. It depends on the font, but it looks
> > > very much like the backtick. This may lead to mistakes.
>
> I of course meant that a backtick looks very much like a single quote.
>
> > OK, that's fair enough Bram (although I don't personally find it
> > confusing and, as noted, this _is_ already used by
> > javascript/typescript so clearly many people find it acceptable).
>
> These decisions are often made by a committee, it doesn't mean it's
> always a good idea. Perhaps they used a font where it is not a problem.
> For Vim it's nice if we can use a syntax that script writers recognize,
> but we also want to avoid things that have turned out to be a
> not-so-great choice.
>
> There are other languages where a prefix to a string changes the meaning
> of that string, we can at least follow that pattern.
>
> > My one last statement in favour of the javascript/typescript syntax is
> > that vim already uses the `{}` interpolation characters in `:h
> > curly_brace_names`, where it is possible in vimscript to do this:
> >
> > ```vim
> > let my_{&filetype}_variable = 'something';
> > ```
> >
> > It would be nice and consistent to then be able to do this:
> >
> > ```vim
> > let my_{&filetype}_variable = `something {&filetype}-specific`;
> > ```
>
> The use of {} like that has been deprecated, there are too many subtle
> corner cases with it. I also don't see it used much.
>

The taglist plugin (which was developed back in 2002 and widely used)
heavily uses the curly brace syntax in variables. This was implemented
before Lists/Dicts were added to Vim.

https://www.vim.org/scripts/script.php?script_id=273
http://vim-taglist.sourceforge.net/index.html

- Yegappan

-- 
-- 
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].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_dev/CAAW7x7%3DHwG%2BfjTYpL6haUv7FiSvk5%2Bp9i0M6btR%3Dv2uze_cHww%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Raspunde prin e-mail lui