File tree Expand file tree Collapse file tree 4 files changed +11
-11
lines changed
java/ql/test/library-tests
python/ql/lib/semmle/python Expand file tree Collapse file tree 4 files changed +11
-11
lines changed Original file line number Diff line number Diff line change @@ -55,7 +55,7 @@ class JaxRsTest extends InlineExpectationsTest {
5555 or
5656 tag = "ResourceMethodOnResourceClass" and
5757 exists ( JaxRsResourceMethod resourceMethod |
58- resourceMethod = any ( JaxRsResourceClass ResourceClass ) .getAResourceMethod ( )
58+ resourceMethod = any ( JaxRsResourceClass resourceClass ) .getAResourceMethod ( )
5959 |
6060 resourceMethod .getLocation ( ) = location and
6161 element = resourceMethod .toString ( ) and
Original file line number Diff line number Diff line change @@ -2,8 +2,8 @@ import semmle.code.java.Type
22
33predicate typeIsInCU ( Type tpe , CompilationUnit cu ) { tpe .getCompilationUnit ( ) = cu }
44
5- from Type tpe , CompilationUnit Ajava
5+ from Type tpe , CompilationUnit aJava
66where
7- Ajava .hasName ( "A" ) and
8- typeIsInCU ( tpe , Ajava )
7+ aJava .hasName ( "A" ) and
8+ typeIsInCU ( tpe , aJava )
99select tpe
Original file line number Diff line number Diff line change @@ -27,9 +27,9 @@ class FunctionMetrics extends Function {
2727 * P = the number of connected components, which for a single function is 1.
2828 */
2929 int getCyclomaticComplexity ( ) {
30- exists ( int E , int N |
31- N = count ( BasicBlock b | b = this .getABasicBlock ( ) and b .likelyReachable ( ) ) and
32- E =
30+ exists ( int e , int n |
31+ n = count ( BasicBlock b | b = this .getABasicBlock ( ) and b .likelyReachable ( ) ) and
32+ e =
3333 count ( BasicBlock b1 , BasicBlock b2 |
3434 b1 = this .getABasicBlock ( ) and
3535 b1 .likelyReachable ( ) and
@@ -39,7 +39,7 @@ class FunctionMetrics extends Function {
3939 not b1 .unlikelySuccessor ( b2 )
4040 )
4141 |
42- result = E - N + 2
42+ result = e - n + 2
4343 )
4444 }
4545
Original file line number Diff line number Diff line change @@ -18,9 +18,9 @@ predicate mapping_format(StrConst e) {
1818 */
1919
2020private string conversion_specifier_string ( StrConst e , int number , int position ) {
21- exists ( string s , string REGEX | s = e .getText ( ) |
22- REGEX = "%(\\([^)]*\\))?[#0\\- +]*(\\*|[0-9]*)(\\.(\\*|[0-9]*))?(h|H|l|L)?[badiouxXeEfFgGcrs%]" and
23- result = s .regexpFind ( REGEX , number , position )
21+ exists ( string s , string regex | s = e .getText ( ) |
22+ regex = "%(\\([^)]*\\))?[#0\\- +]*(\\*|[0-9]*)(\\.(\\*|[0-9]*))?(h|H|l|L)?[badiouxXeEfFgGcrs%]" and
23+ result = s .regexpFind ( regex , number , position )
2424 )
2525}
2626
You can’t perform that action at this time.
0 commit comments