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

Proposed: option.overparam

Expand Messages
  • Rob Richardson
    I d like to know when I ve passed in more parameters than the function will use: /*jslint white: true, onevar: true, undef: true, nomen: true, regexp: true,
    Message 1 of 9 , May 7 8:32 AM
    • 0 Attachment
      I'd like to know when I've passed in more parameters than the function will
      use:

      /*jslint white: true, onevar: true, undef: true, nomen: true, regexp: true,
      plusplus: true, bitwise: true, newcap: true */
      (function () {
      `
      ` var a = function (one, two) {
      ` // ...
      ` };
      `
      ` a(1, 2, 3); // <-- I've passed in too many
      `
      }());

      I grant that some functions declare themselves as having no (or fewer)
      parameters, then inspect arguments to handle them all, but this is confusing
      for the novice user of this code.

      Rob
    Your message has been successfully submitted and would be delivered to recipients shortly.