Hacker News new | ask | show | jobs
by a1369209993 2144 days ago
That is true, but has nothing to do with "==" vs "=" vs ":=". You can do:

  func(x = 42); /* syntax error: expression operator expected, got '=' */
  x = 42; /* OK */
  x == 42; /* warning: statement expression has no effect */
just fine if you require "=" to be a statement.