Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 9e2a3a9 commit 90365c9Copy full SHA for 90365c9
1 file changed
java/ql/consistency-queries/BinaryExpr.ql
@@ -0,0 +1,8 @@
1
+import java
2
+
3
+from BinaryExpr be, string reason
4
+where not exists(be.getLeftOperand()) and reason = "No left operand"
5
+ or not exists(be.getRightOperand()) and reason = "No right operand"
6
+ or exists(Expr e, int i | e.isNthChildOf(be, i) and i != 0 and i != 1 and reason = "Unexpected operand " + i.toString())
7
+ or be.getOp() = " ?? " and reason = "No operator name"
8
+select be, reason
0 commit comments