MarcWeber/vim-addon-manager — comment on commit 65278d0eefb5ee295c6a660a783d7010c6302dc0
File:  line 0
By ZyX-I:

There are some things why this function is much worse then mine:

1. It has self time of 0.25 and mine has self time of 0.11 (with all but first three filters removed, 0.32 with all filters) called with

vim -N -u NONE --cmd 'let g:vim_addon_manager={"plugin_root_dir": "~/.vam"}' --cmd 'let &rtp="~/tmp/vim/vim-addon-manager"' -c 'profile start profile.log' -c 'profile func vam#install#*' -c 'call writefile(vam#install#DoCompletion("ult*snips", "ult*snips", len("ult*snips")), "result")' -c 'qa!'

I do use `map()`+side-effects not because I like cryptic functions.

2. It does not provide completion for `utlsnips` (second and third letters were swapped). You also need adjustments to three places to add a new filter, not to one (or two if you don’t want to put regex inside a filter so that it can be reused in another).

3. I do not understand the names: `c`, `m`, `p`, `n`.