All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.sonar.l10n.javascript.rules.javascript.Parentheses.html Maven / Gradle / Ivy

There is a newer version: 2.5
Show newest version

Avoid use of parentheses where not required by syntax or semantics.

The following code snippet illustrates this rule :

function sayHello() {
  var a = typeof (37); // Non-Compliant
  var b = typeof 38;

  var c = {};
  c.a = a;
  c.b = b;
  delete (a); // Non-Compliant
  delete b;

  void 0;
  void (1); // Non-Compliant
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy