Loading ...
Sorry, an error occurred while loading the content.

preset param value in vimscript func

Expand Messages
  • niva
    Hi, I would like to know , as in C++, how can I set a value by default into the second arg of a vimscript func in order to call the fu with only one arg out of
    Message 1 of 1 , Aug 25, 2011
    • 0 Attachment
      Hi,

      I would like to know , as in C++, how can I set a value by default
      into the second arg of a vimscript func in order to call the fu with
      only one arg out of two required;

      fu bar(arg1, arg2=20)
      //todo
      endfu

      I would like the call looks like that:

      call bar("foo")

      --
      You received this message from the "vim_use" 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
    Your message has been successfully submitted and would be delivered to recipients shortly.