> On Sunday, February 26, 2023 at 6:48:16 PM UTC-5 lacygoill wrote: > > Here is an example: > function s:Func() echomsg 'hello from s:Func' endfunction nnoremap <F3> : > call <SID>Func()<CR> > > I have always written that as `:nnoremap <leader>X :call s:Func()<enter>` > without trouble (_i.e._, it works). But you seem to be saying that `<SID>` > is required… am I relying on a bug?
At some point in the past using "s:" in a mapping was made to work, by setting the script context of where the mapping was defined. Before that using <SID> was required. -- I'm in shape. Round IS a shape. /// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net \\\ /// \\\ \\\ sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ /// \\\ help me help AIDS victims -- http://ICCF-Holland.org /// -- -- 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/20230227154531.1FED51C0E92%40moolenaar.net.
