-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA256 On 11-Aug-2019 18:51 +0200, 'Andy Wokula' via vim_dev wrote: > Am 11.08.2019 um 18:27 schrieb Bram Moolenaar: >> I'm not sure about methods for a specific type, e.g. only defined >> for a list or dict. I suppose in many cases you have very >> similar functionality in both, and might as well define both. >> >> It would be possible to make the type available to the >> autocommand. But it feels like this is getting more complicated >> than needed. That is also the main reason I asked: Do we >> want/need to select the function based on the type? > > If you ask me: no. I want to be able to build these things using > Vim script because then it's backwards compatible. > > I wish there was a *small* Vim script core (already too late). > > I'm with JM Keyes there: we don't need more syntactic (or > syntoxic!!) sugar.
I agree with Andy and Justin. The vast majority of plugins are small enough to be written in a procedural style, and any desire to do some simple object orientation can be satisfied via Dictionary functions alread. For anything larger or complex, I would use another embedded language, of which Vim supports many (depending on the build, but both Python and Perl have very fine and powerful object-orientation and are commonly available). The discussion about type annotation and how FuncUndefined would be affected already shows how hard it is to retrofit these features into the existing language. (Java did this with generics and closures - but both still left many unsatisfied with the chosen design, and it took several committees a long time.) I'd rather have the effort spent on adding more low-level functions (like the recent chdir() and sign_*() additions), and to work on the huge todo list; there are still so many outstanding patches and bugs. The addition of Lists, Dictionaries and many other things in Vim 7.0 was a good thing - it enabled effective plugin development, and people desperate for these features were already emulating these poorly on their own. With the recent addition of closures (which I still hesitate to use - I still encounter Vim 7.4 on some Ubuntu 16.04 LTS systems), I think we're now firmly in the area of diminishing returns when it comes to language features. - -- regards, ingo -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQEcBAEBCAAGBQJdUE56AAoJEA7ziXlAzQ/vgBgH/1GX7m7J+NFn56vVrIkiFy/e hirGIQMdMDk9FiJeqx/EZsCwX61KlVJX5PVp+Kcsw7WL04xKKzEqa1wKIQZTWKPi iXb2oUyWOtkDMaJG7SRLFXkFmLldVdZjLUaUl5HFoLJ5W+0gSSUNUTwa62NB5OlC P63waSB0yVwCvhmaeKOl0BS0bLsvhHjUbOgj+kuCDJHiR7aikOL/39EJwfaWrkdx VwJ7naTth9ZnzsLSG7HvUhrZAn+ozJkh6R94b/7PVOtdBL0VrFi+c9A+wQP/cykB J55T7D7BaCQLnS12m63c5nSA6GQ7qSEp1NpUZ1jkSBGec2EMbjPLdXXWIs8A15w= =puBU -----END PGP SIGNATURE----- -- -- 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/4ece52e1-33c0-68fd-c7d9-002f20d094f1%40ingo-karkat.de.
