On Thursday, 29 January 2015 at 13:58:52 UTC, Jacob Carlborg wrote:
A good language design that doesn't require the ; statement terminator would recognize "void func()" as a valid statement and implicit add ;. Scan the line, if a valid language construct has been seen at the end of the line, insert a ;, if not continue to the next line. That works in many languages.

Tells me what this function returns in javascript :
function foo()
{
  return
  {
    foo: "bar",
  }
}

Yes, you guessed right, it returns undefined. Ho you didn't ? What a surprise !

Reply via email to