cranelift: Add is_bool_vector helper

This commit is contained in:
Afonso Bordado
2021-09-10 15:46:14 +01:00
parent 85d468dc5a
commit 3c1133379c
2 changed files with 7 additions and 6 deletions

View File

@@ -208,6 +208,11 @@ impl Type {
}
}
/// Is this a vector boolean type?
pub fn is_bool_vector(self) -> bool {
self.is_vector() && self.lane_type().is_bool()
}
/// Is this a scalar integer type?
pub fn is_int(self) -> bool {
match self {