mirror of
https://github.com/github/codeql.git
synced 2025-12-16 16:53:25 +01:00
Rust: Autoformat.
This commit is contained in:
@@ -34,24 +34,21 @@ class BuiltinType extends Struct {
|
||||
/**
|
||||
* A numerical type, such as `i64`, `usize`, `f32` or `f64`.
|
||||
*/
|
||||
abstract private class NumericTypeImpl extends BuiltinType {
|
||||
}
|
||||
abstract private class NumericTypeImpl extends BuiltinType { }
|
||||
|
||||
final class NumericType = NumericTypeImpl;
|
||||
|
||||
/**
|
||||
* An integral numerical type, such as `i64` or `usize`.
|
||||
*/
|
||||
abstract private class IntegralTypeImpl extends NumericTypeImpl {
|
||||
}
|
||||
abstract private class IntegralTypeImpl extends NumericTypeImpl { }
|
||||
|
||||
final class IntegralType = IntegralTypeImpl;
|
||||
|
||||
/**
|
||||
* A floating-point numerical type, such as `f32` or `f64`.
|
||||
*/
|
||||
abstract private class FloatingPointTypeImpl extends NumericTypeImpl {
|
||||
}
|
||||
abstract private class FloatingPointTypeImpl extends NumericTypeImpl { }
|
||||
|
||||
final class FloatingPointType = FloatingPointTypeImpl;
|
||||
|
||||
|
||||
@@ -96,5 +96,6 @@ module RegexInjection {
|
||||
* We don't include floating point types in this barrier, as `.` is a special character
|
||||
* in regular expressions.
|
||||
*/
|
||||
private class IntegralOrBooleanTypeBarrier extends Barrier instanceof Barriers::IntegralOrBooleanTypeBarrier { }
|
||||
private class IntegralOrBooleanTypeBarrier extends Barrier instanceof Barriers::IntegralOrBooleanTypeBarrier
|
||||
{ }
|
||||
}
|
||||
|
||||
@@ -3,11 +3,11 @@ import codeql.rust.frameworks.stdlib.Builtins
|
||||
import codeql.rust.internal.Type
|
||||
|
||||
string describe(BuiltinType t) {
|
||||
(t instanceof NumericType and result = "NumericType")
|
||||
t instanceof NumericType and result = "NumericType"
|
||||
or
|
||||
(t instanceof IntegralType and result = "IntegralType")
|
||||
t instanceof IntegralType and result = "IntegralType"
|
||||
or
|
||||
(t instanceof FloatingPointType and result = "FloatingPointType")
|
||||
t instanceof FloatingPointType and result = "FloatingPointType"
|
||||
}
|
||||
|
||||
from BuiltinType t
|
||||
|
||||
Reference in New Issue
Block a user