Check if this type is a numeric type
(&self)
| 1492 | |
| 1493 | /// Check if this type is a numeric type |
| 1494 | pub fn is_numeric(&self) -> bool { |
| 1495 | matches!( |
| 1496 | self, |
| 1497 | TypeSpec::Decimal { .. } |
| 1498 | | TypeSpec::Integer |
| 1499 | | TypeSpec::BigInt |
| 1500 | | TypeSpec::SmallInt |
| 1501 | | TypeSpec::Int128 |
| 1502 | | TypeSpec::Int256 |
| 1503 | | TypeSpec::Float { .. } |
| 1504 | | TypeSpec::Real |
| 1505 | | TypeSpec::Double |
| 1506 | ) |
| 1507 | } |
| 1508 | |
| 1509 | /// Check if this is an exact numeric type (integer or decimal) |
| 1510 | pub fn is_exact_numeric(&self) -> bool { |
no outgoing calls
no test coverage detected