Remove isIntegerNumber and isFloatingNumber
This commit is contained in:
@@ -298,20 +298,6 @@ pub fn isNumber(comptime T: type) bool {
|
||||
};
|
||||
}
|
||||
|
||||
pub fn isIntegerNumber(comptime T: type) bool {
|
||||
return switch (@typeInfo(T)) {
|
||||
.Int, .ComptimeInt => true,
|
||||
else => false,
|
||||
};
|
||||
}
|
||||
|
||||
pub fn isFloatingNumber(comptime T: type) bool {
|
||||
return switch (@typeInfo(T)) {
|
||||
.Float, .ComptimeFloat => true,
|
||||
else => false,
|
||||
};
|
||||
}
|
||||
|
||||
test "std.meta.trait.isNumber" {
|
||||
const NotANumber = struct {
|
||||
number: u8,
|
||||
|
||||
Reference in New Issue
Block a user