use crate::type_aliases::type_id::TypeId;
use alloc::vec::Vec;
#[derive(Debug, Clone, PartialEq, Eq, Hash)]
pub struct RefinementPartition {
pub(crate) discriminant_types: Vec<TypeId>,
pub(crate) should_append_nil_type: bool,
}
impl Default for RefinementPartition {
fn default() -> Self {
Self {
discriminant_types: Vec::new(),
should_append_nil_type: false,
}
}
}
#[allow(non_snake_case)]
impl RefinementPartition {
pub fn discriminantTypes(&self) -> &[TypeId] {
&self.discriminant_types
}
pub fn shouldAppendNilType(&self) -> bool {
self.should_append_nil_type
}
}