Skip to content

Commit e8c9708

Browse files
committed
Autoformat
1 parent 09e83d1 commit e8c9708

File tree

24 files changed

+26
-65
lines changed

24 files changed

+26
-65
lines changed

java/ql/integration-tests/all-platforms/kotlin/nested_generic_types/test.ql

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,7 @@ query predicate nestedTypes(NestedType nt, RefType parent) {
3030
parent = nt.getEnclosingType()
3131
}
3232

33-
query predicate javaKotlinCalleeAgreement(
34-
MethodCall javaMa, MethodCall kotlinMa, Callable callee
35-
) {
33+
query predicate javaKotlinCalleeAgreement(MethodCall javaMa, MethodCall kotlinMa, Callable callee) {
3634
javaMa.getCallee() = callee and
3735
kotlinMa.getCallee() = callee and
3836
javaMa.getFile().getExtension() = "java" and

java/ql/lib/semmle/code/java/Expr.qll

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1251,7 +1251,7 @@ class ClassInstanceExpr extends Expr, ConstructorCall, @classinstancexpr {
12511251
override string getAPrimaryQlClass() { result = "ClassInstanceExpr" }
12521252
}
12531253

1254-
/**
1254+
/**
12551255
* An explicit `new ClassName(...)` expression.
12561256
*
12571257
* Note this does not include implicit instance creation such as lambda expressions

java/ql/lib/semmle/code/java/dataflow/InstanceAccess.qll

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -58,9 +58,7 @@ private predicate implicitEnclosingThisCopy(ConstructorCall cc, RefType t1, RefT
5858
private predicate enclosingInstanceAccess(ExprParent e, RefType t) {
5959
e.(InstanceAccess).isEnclosingInstanceAccess(t)
6060
or
61-
exists(MethodCall ma |
62-
ma.isEnclosingMethodCall(t) and ma = e and not exists(ma.getQualifier())
63-
)
61+
exists(MethodCall ma | ma.isEnclosingMethodCall(t) and ma = e and not exists(ma.getQualifier()))
6462
or
6563
exists(FieldAccess fa | fa.isEnclosingFieldAccess(t) and fa = e and not exists(fa.getQualifier()))
6664
or

java/ql/lib/semmle/code/java/dataflow/internal/TaintTrackingUtil.qll

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -466,9 +466,7 @@ class ObjectOutputStreamVar extends LocalVariableDecl {
466466
}
467467

468468
/** DEPRECATED: Alias for `getAWriteObjectMethodCall`. */
469-
deprecated MethodCall getAWriteObjectMethodAccess() {
470-
result = this.getAWriteObjectMethodCall()
471-
}
469+
deprecated MethodCall getAWriteObjectMethodAccess() { result = this.getAWriteObjectMethodCall() }
472470
}
473471

474472
/** Flow through string formatting. */

java/ql/lib/semmle/code/java/frameworks/Mockito.qll

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -78,9 +78,7 @@ class MockitoInitedTest extends Class {
7878
m.calls*(initMocks)
7979
)
8080
or
81-
exists(MethodCall call | call.getCallee() = initMocks |
82-
call.getArgument(0).getType() = this
83-
)
81+
exists(MethodCall call | call.getCallee() = initMocks | call.getArgument(0).getType() = this)
8482
)
8583
}
8684
}

java/ql/lib/semmle/code/java/os/OSCheck.qll

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -158,9 +158,8 @@ private class IsUnixFromPosixFromFileSystem extends IsUnixGuard instanceof Metho
158158
supportedFileAttributeViewsMethod.hasName("supportedFileAttributeViews") and
159159
supportedFileAttributeViewsMethod.getDeclaringType() instanceof TypeFileSystem
160160
|
161-
DataFlow::localExprFlow(any(MethodCall ma |
162-
ma.getMethod() = supportedFileAttributeViewsMethod
163-
), super.getQualifier())
161+
DataFlow::localExprFlow(any(MethodCall ma | ma.getMethod() = supportedFileAttributeViewsMethod),
162+
super.getQualifier())
164163
)
165164
}
166165
}

java/ql/lib/semmle/code/java/security/FileReadWrite.qll

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,7 @@ private predicate directFileRead(Expr fileAccess, Expr fileReadingExpr) {
1313
.hasQualifiedName("java.io", ["RandomAccessFile", "FileReader", "FileInputStream"])
1414
)
1515
or
16-
exists(MethodCall ma, Method filesMethod |
17-
ma = fileReadingExpr and filesMethod = ma.getMethod()
18-
|
16+
exists(MethodCall ma, Method filesMethod | ma = fileReadingExpr and filesMethod = ma.getMethod() |
1917
(
2018
// Identify all method calls on the `Files` class that imply that we are reading the file
2119
// represented by the first argument.

java/ql/lib/semmle/code/java/security/HardcodedCredentialsComparison.qll

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,7 @@ deprecated class EqualsAccess = EqualsCall;
1818
/**
1919
* Holds if `sink` compares password `p` against a hardcoded expression `source`.
2020
*/
21-
predicate isHardcodedCredentialsComparison(
22-
EqualsCall sink, HardcodedExpr source, PasswordVariable p
23-
) {
21+
predicate isHardcodedCredentialsComparison(EqualsCall sink, HardcodedExpr source, PasswordVariable p) {
2422
source = sink.getQualifier() and
2523
p.getAnAccess() = sink.getArgument(0)
2624
or

java/ql/lib/semmle/code/java/security/PartialPathTraversal.qll

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,4 +60,4 @@ class PartialPathTraversalMethodCall extends MethodCall {
6060
}
6161

6262
/** DEPRECATED: Alias for `PartialPathTraversalMethodCall`. */
63-
deprecated class PartialPathTraversalMethodAccess = PartialPathTraversalMethodCall;
63+
deprecated class PartialPathTraversalMethodAccess = PartialPathTraversalMethodCall;

java/ql/lib/semmle/code/java/security/TempDirLocalInformationDisclosureQuery.qll

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -260,4 +260,5 @@ class MethodCallInsecureGuavaFilesCreateTempFile extends MethodCallInsecureFileC
260260
}
261261

262262
/** DEPRECATED: Alias for `MethodCallInsecureGuavaFilesCreateTempFile`. */
263-
deprecated class MethodAccessInsecureGuavaFilesCreateTempFile = MethodCallInsecureGuavaFilesCreateTempFile;
263+
deprecated class MethodAccessInsecureGuavaFilesCreateTempFile =
264+
MethodCallInsecureGuavaFilesCreateTempFile;

0 commit comments

Comments
 (0)