Yassin Kammoun
Yassin Kammoun
Depends on #2543
We currently raise issues for numeric arrays only, but we can improve the rule and extend its scope to raise on non-string-like arrays. We define a string-like data type as...
When computing cyclomatic complexity, SonarJS used to ignore function expressions passed to method calls on Angular modules: ```javascript var m = angular.module("moduleX"); m.controller("name", function() { ... }); ``` This was...
#1653 introduced a rule for function-level cyclomatic complexity. To be consistent with the rule implementation, we need to also ignore AMD pattern and immediately invoked functions at-file level.
```javascript let value = /*... */ ; while (value < foo()) { /* ... */ } ``` Reported in https://community.sonarsource.com/t/false-positive-for-indefinite-loop-with-multiple-conditions-javascript-s2189/44970/3
```javascript let condition = true; async function foo() { /* ... */ while (condition) { // FP: condition is modified asynchronously /* ...: does not modify condition */ } }...
Fixes #3405
The rule S109 ('no-magic-numbers') reports false positives for numeric literal types: ```typescript type Zero = 0; type Five = 5; ``` To kill the noise, we need to enable the...