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

1200Function return with and without value does not give any warning

Expand Messages
  • Woomla
    Mar 5, 2010
      The code snippet below doesn't give any errors or warnings. But return with and without a value is used. Shouldn't that at least issue a warning?


      "use strict";

      function test(a, b)
      {
      if (a)
      {
      return true;
      }
      if (b)
      {
      return;
      }
      }
    • Show all 7 messages in this topic