Re: Vim9 dict key notation old fashion depreciated

2020-12-06 Thread Ni Va
Replacing by This seems good: \ networks: { *['' .. string(currnetwork) ]*: foo.undercursor.variable } Le dimanche 6 décembre 2020 à 19:27:47 UTC+1, Ni Va a écrit : > Is this notation below in red unavailable since recent Vim commits (upper > to 8.2.2194) ? > >

Re: Vim9 dict key notation old fashion depreciated

2020-12-06 Thread Ni Va
Is this notation below in red unavailable since recent Vim commits (upper to 8.2.2194) ? s:higherInfos[apiFileLocation] = \{ blockname: \ { totalnetworks: totalnetworks, \ blocknumber: blocknumber, \ networks: { *string(currnetwork)*: foo.undercursor.variable } \}

Re: Vim9 dict key notation old fashion depreciated

2020-12-04 Thread Bram Moolenaar
> I'm not a cython or python expert but I'm working on a project that has > this kind of code. > It was just a reflection in the sense that for me vim9 script is > precompiled as a cython and not as a python. > > The comparison for me has meaning between two pre-compiled languages. Out >

Re: Vim9 dict key notation old fashion depreciated

2020-12-04 Thread Ni Va
I'm not a cython or python expert but I'm working on a project that has this kind of code. It was just a reflection in the sense that for me vim9 script is precompiled as a cython and not as a python. The comparison for me has meaning between two pre-compiled languages. Out of mistake on my

Re: Vim9 dict key notation old fashion depreciated

2020-12-04 Thread Christian Brabandt
On Fr, 04 Dez 2020, Ni Va wrote: > Why Benchmark does not compare Vim9 to cython instead of python ? Because nobody has done it. If you can provide benchmarking results, feel free to open a PR with those additional informations. Best, Christian -- Frage: Welche Hardwareplattform eignet

Re: Vim9 dict key notation old fashion depreciated

2020-12-04 Thread Ni Va
Why Benchmark does not compare Vim9 to cython instead of python ? Le jeudi 3 décembre 2020 à 17:48:20 UTC+1, Dominique Pelle a écrit : > On Thu, Dec 3, 2020 at 1:55 PM Ni Va wrote: > > > Do profiler show performance gain for vimscript migrated in vim9 ? > > You can see vim9 benchmarks at: >

Re: Vim9 dict key notation old fashion depreciated

2020-12-03 Thread Felipe Contreras
On Thu, Dec 3, 2020 at 10:10 AM Bram Moolenaar wrote: > Oh, you mean using single quotes without the brackets works. Double > quotes too. That is simpler. Somehow I didn't find this in the > specification. I see questions on stack overflow from more people who > are confused about this.

Re: Vim9 dict key notation old fashion depreciated

2020-12-03 Thread Dominique Pellé
On Thu, Dec 3, 2020 at 1:55 PM Ni Va wrote: > Do profiler show performance gain for vimscript migrated in vim9 ? You can see vim9 benchmarks at: https://github.com/vim/vim/blob/master/README_VIM9.md That README_VIM9.md file contains the sources of the benchmarks, so you can run them yourself

Re: Vim9 dict key notation old fashion depreciated

2020-12-03 Thread Bram Moolenaar
> It's okay with this new notation and thank you for less chars as backslash. > > Do profiler show performance gain for vimscript migrated in vim9 ? > > g:fzf_colors =3D { fg: ['fg', 'Normal'], > bg: ["bg", "Normal"], > hl: ["fg", "IncSearch"], > info: ["fg", "IncSearch"], > border: ["fg",

Re: Vim9 dict key notation old fashion depreciated

2020-12-03 Thread Bram Moolenaar
Filipe Contreras wrote: > On Thursday, December 3, 2020 at 5:34:04 AM UTC-6 Bram Moolenaar wrote: > > > Looks like your problem is with the "fg+" key, the plus character is not > > allowed in a literal key. You can use the Javascript notation, using > > square brackets: > > ['fg+']: ["fg",

Re: Vim9 dict key notation old fashion depreciated

2020-12-03 Thread arocker
Vocabulary pedant writing here. Though the meaning is obvious in this context, "depreciate" means to lose value, e.g. when a new car is driven off the lot, its value depreciates 25% or so. To express disapproval of something, "deprecate" it. There's just an iota of difference between

Re: Vim9 dict key notation old fashion depreciated

2020-12-03 Thread Ni Va
Okay thank you for feedback. if I were joking I would say that all it takes is an advanced substitute to migrate the vimscript dictionaries to vim9. In my plugins, certainly not in vim-airline :) Le jeudi 3 décembre 2020 à 14:00:26 UTC+1, cbl...@256bit.org a écrit : > > On Do, 03 Dez 2020, Ni

Re: Vim9 dict key notation old fashion depreciated

2020-12-03 Thread Christian Brabandt
On Do, 03 Dez 2020, Ni Va wrote: > It's okay with this new notation and thank you for less chars as backslash. > > Do profiler show performance gain for vimscript migrated in vim9 ? You can profile a vim9 script version and a legacy vimscript version. That's what I did with the switch on

Re: Vim9 dict key notation old fashion depreciated

2020-12-03 Thread Ni Va
It's okay with this new notation and thank you for less chars as backslash. Do profiler show performance gain for vimscript migrated in vim9 ? g:fzf_colors = { fg: ['fg', 'Normal'], bg: ["bg", "Normal"], hl: ["fg", "IncSearch"], info: ["fg", "IncSearch"], border: ["fg", "Ignore"], prompt: ["fg",

Re: Vim9 dict key notation old fashion depreciated

2020-12-03 Thread Felipe Contreras
On Thursday, December 3, 2020 at 5:34:04 AM UTC-6 Bram Moolenaar wrote: > Looks like your problem is with the "fg+" key, the plus character is not > allowed in a literal key. You can use the Javascript notation, using > square brackets: ... ['fg+']: ["fg", "CursorLine", "CursorColumn",

Re: Vim9 dict key notation old fashion depreciated

2020-12-03 Thread Bram Moolenaar
> This, as a bypass, seems to work: > > g:fzf_colors = { fg: ['fg', 'Normal'], >\ bg: ["bg", "Normal"], >\ hl: ["fg", "IncSearch"], >\ info:["fg", "IncSearch"], >\ border: ["fg", "Ignore"], >\ prompt:

Re: Vim9 dict key notation old fashion depreciated

2020-12-03 Thread Ni Va
This, as a bypass, seems to work: g:fzf_colors = { fg: ['fg', 'Normal'], \ bg: ["bg", "Normal"], \ hl: ["fg", "IncSearch"], \ info:["fg", "IncSearch"], \ border: ["fg", "Ignore"], \ prompt: ["fg", "Comment"],

Vim9 dict key notation old fashion depreciated

2020-12-03 Thread Ni Va
Hi, Since Vim.8.2.2082, it appears that this notation of dict' keys used for example in FZF plugin is depreciated. g:fzf_colors = { fg: ['fg', 'Normal'], \ bg: ["bg", "Normal"], \ hl: ["fg", "IncSearch"], \ fg+: ["fg", "CursorLine",