mirror of
https://github.com/github/codeql.git
synced 2026-04-30 19:26:02 +02:00
Fixup tests from code review changes
This commit is contained in:
@@ -518,11 +518,11 @@ constants/Values.java:
|
||||
# 90| 0: [VarAccess] var_field
|
||||
# 91| 68: [LocalVariableDeclStmt] var ...;
|
||||
# 91| 0: [TypeAccess] String
|
||||
# 91| 1: [LocalVariableDeclExpr] concatinatedString
|
||||
# 91| 1: [LocalVariableDeclExpr] concatenatedString
|
||||
# 91| 0: [StringLiteral] "a" + "b"
|
||||
# 92| 69: [LocalVariableDeclStmt] var ...;
|
||||
# 92| 0: [TypeAccess] String
|
||||
# 92| 1: [LocalVariableDeclExpr] concatinatedChar
|
||||
# 92| 1: [LocalVariableDeclExpr] concatenatedChar
|
||||
# 92| 0: [AddExpr] ... + ...
|
||||
# 92| 0: [StringLiteral] "ab"
|
||||
# 92| 1: [CharacterLiteral] 'c'
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
import semmle.code.java.Variable
|
||||
|
||||
from Variable v, Expr init, RefType enclosing, boolean constant
|
||||
from Variable v, CompileTimeConstantExpr init, RefType enclosing, boolean constant
|
||||
where
|
||||
v.getInitializer() = init and
|
||||
init.getEnclosingCallable().getDeclaringType() = enclosing and
|
||||
enclosing.hasQualifiedName("constants", "Values") and
|
||||
constant = init.(CompileTimeConstantExpr).getBooleanValue()
|
||||
constant = init.getBooleanValue()
|
||||
select init, constant
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
import semmle.code.java.Variable
|
||||
|
||||
from Variable v, Expr init, RefType enclosing, int constant
|
||||
from Variable v, CompileTimeConstantExpr init, RefType enclosing, int constant
|
||||
where
|
||||
v.getInitializer() = init and
|
||||
init.getEnclosingCallable().getDeclaringType() = enclosing and
|
||||
enclosing.hasQualifiedName("constants", "Values") and
|
||||
constant = init.(CompileTimeConstantExpr).getIntValue()
|
||||
constant = init.getIntValue()
|
||||
select init, constant
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
| constants/Values.java:19:29:19:31 | '*' | * |
|
||||
| constants/Values.java:91:37:91:45 | "a" + "b" | ab |
|
||||
| constants/Values.java:92:29:92:38 | ... + ... | abc |
|
||||
| constants/Values.java:92:35:92:44 | ... + ... | abc |
|
||||
|
||||
Reference in New Issue
Block a user