Skip to content

Commit 8548c16

Browse files
committed
Rust: Autoformat.
1 parent 34f7595 commit 8548c16

File tree

3 files changed

+8
-10
lines changed

3 files changed

+8
-10
lines changed

rust/ql/lib/codeql/rust/frameworks/stdlib/Builtins.qll

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -34,24 +34,21 @@ class BuiltinType extends Struct {
3434
/**
3535
* A numerical type, such as `i64`, `usize`, `f32` or `f64`.
3636
*/
37-
abstract private class NumericTypeImpl extends BuiltinType {
38-
}
37+
abstract private class NumericTypeImpl extends BuiltinType { }
3938

4039
final class NumericType = NumericTypeImpl;
4140

4241
/**
4342
* An integral numerical type, such as `i64` or `usize`.
4443
*/
45-
abstract private class IntegralTypeImpl extends NumericTypeImpl {
46-
}
44+
abstract private class IntegralTypeImpl extends NumericTypeImpl { }
4745

4846
final class IntegralType = IntegralTypeImpl;
4947

5048
/**
5149
* A floating-point numerical type, such as `f32` or `f64`.
5250
*/
53-
abstract private class FloatingPointTypeImpl extends NumericTypeImpl {
54-
}
51+
abstract private class FloatingPointTypeImpl extends NumericTypeImpl { }
5552

5653
final class FloatingPointType = FloatingPointTypeImpl;
5754

rust/ql/lib/codeql/rust/security/regex/RegexInjectionExtensions.qll

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,5 +96,6 @@ module RegexInjection {
9696
* We don't include floating point types in this barrier, as `.` is a special character
9797
* in regular expressions.
9898
*/
99-
private class IntegralOrBooleanTypeBarrier extends Barrier instanceof Barriers::IntegralOrBooleanTypeBarrier { }
99+
private class IntegralOrBooleanTypeBarrier extends Barrier instanceof Barriers::IntegralOrBooleanTypeBarrier
100+
{ }
100101
}

rust/ql/test/library-tests/elements/builtintypes/BuiltinTypes.ql

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,11 @@ import codeql.rust.frameworks.stdlib.Builtins
33
import codeql.rust.internal.Type
44

55
string describe(BuiltinType t) {
6-
(t instanceof NumericType and result = "NumericType")
6+
t instanceof NumericType and result = "NumericType"
77
or
8-
(t instanceof IntegralType and result = "IntegralType")
8+
t instanceof IntegralType and result = "IntegralType"
99
or
10-
(t instanceof FloatingPointType and result = "FloatingPointType")
10+
t instanceof FloatingPointType and result = "FloatingPointType"
1111
}
1212

1313
from BuiltinType t

0 commit comments

Comments
 (0)