Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 22c218d

Browse files
committed
JS: Mark a 'good' test as 'bad' and add Alert marker
The lack of whitespace around '&&' is problematic
1 parent a9b263f commit 22c218d

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

  • javascript/ql/test/query-tests/Expressions/WhitespaceContradictsPrecedence

javascript/ql/test/query-tests/Expressions/WhitespaceContradictsPrecedence/tst.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,8 @@ function ok9(x, y, z) {
3838
return x * y*z;
3939
}
4040

41-
function ok10(o, p) {
42-
return p in o&&o[p];
41+
function bad10(o, p) {
42+
return p in o&&o[p]; // $ Alert
4343
}
4444

4545

0 commit comments

Comments
 (0)