File tree Expand file tree Collapse file tree 1 file changed +3
-12
lines changed
powershell/ql/lib/semmle/code/powershell/ast/internal Expand file tree Collapse file tree 1 file changed +3
-12
lines changed Original file line number Diff line number Diff line change 1
1
private import AstImport
2
+ private import codeql.util.Boolean
2
3
3
4
private newtype TConstantValue =
4
5
TConstInteger ( int value ) {
@@ -12,15 +13,7 @@ private newtype TConstantValue =
12
13
)
13
14
} or
14
15
TConstString ( string value ) { exists ( Raw:: StringLiteral sl | sl .getValue ( ) = value ) } or
15
- TConstBoolean ( boolean value ) {
16
- exists ( Raw:: VarAccess va |
17
- value = true and
18
- va .getUserPath ( ) = "true"
19
- or
20
- value = false and
21
- va .getUserPath ( ) = "false"
22
- )
23
- } or
16
+ TConstBoolean ( Boolean b ) or
24
17
TNull ( )
25
18
26
19
/** A constant value. */
@@ -61,9 +54,7 @@ class ConstInteger extends ConstantValue, TConstInteger {
61
54
62
55
final override string serialize ( ) { result = this .getValue ( ) }
63
56
64
- final override ConstExpr getAnExpr ( ) {
65
- result .getValueString ( ) = this .getValue ( )
66
- }
57
+ final override ConstExpr getAnExpr ( ) { result .getValueString ( ) = this .getValue ( ) }
67
58
}
68
59
69
60
/** A constant floating point value. */
You can’t perform that action at this time.
0 commit comments