pub fn without_modifiers(&self) -> ScalarType {
        use ScalarType::*;
        match self {
            List {
                element_type,
                custom_id: None,
            } => List {
                element_type: Box::new(element_type.without_modifiers()),
                custom_id: None,
            },
            Map {
                value_type,
                custom_id: None,
            } => Map {
                value_type: Box::new(value_type.without_modifiers()),
                custom_id: None,
            },
            Record {
                fields,
                custom_id: None,
            } => {
                let fields = fields
                    .iter()
                    .map(|(column_name, column_type)| {
                        (
                            column_name.clone(),
                            ColumnType {
                                scalar_type: column_type.scalar_type.without_modifiers(),
                                nullable: column_type.nullable,
                            },
                        )
                    })
                    .collect_vec();
                Record {
                    fields,
                    custom_id: None,
                }
            }
            Array(a) => Array(Box::new(a.without_modifiers())),
            Numeric { .. } => Numeric { max_scale: None },
            // Char's default length should not be `Some(1)`, but instead `None`
            // to support Char values of different lengths in e.g. lists.
            Char { .. } => Char { length: None },
            VarChar { .. } => VarChar { max_length: None },
            v => v.clone(),
        }
    }
/// Returns `self` with any type modifiers removed.
///
/// Namely, this should set optional scales or limits to `None`.
Returns `self` with any type modifiers removed.
Namely, this should set optional scales or limits to `None`.
Returns ` self ` with any type modifiers removed . Namely this should set optional scales or limits to ` None ` .
pub fn without_modifiers(&self) -> ScalarType {
        use ScalarType::*;
        match self {
            List {
                element_type,
                custom_id: None,
            } => List {
                element_type: Box::new(element_type.without_modifiers()),
                custom_id: None,
            },
            Map {
                value_type,
                custom_id: None,
            } => Map {
                value_type: Box::new(value_type.without_modifiers()),
                custom_id: None,
            },
            Record {
                fields,
                custom_id: None,
            } => {
                let fields = fields
                    .iter()
                    .map(|(column_name, column_type)| {
                        (
                            column_name.clone(),
                            ColumnType {
                                scalar_type: column_type.scalar_type.without_modifiers(),
                                nullable: column_type.nullable,
                            },
                        )
                    })
                    .collect_vec();
                Record {
                    fields,
                    custom_id: None,
                }
            }
            Array(a) => Array(Box::new(a.without_modifiers())),
            Numeric { .. } => Numeric { max_scale: None },
            // Char's default length should not be `Some(1)`, but instead `None`
            // to support Char values of different lengths in e.g. lists.
            Char { .. } => Char { length: None },
            VarChar { .. } => VarChar { max_length: None },
            v => v.clone(),
        }
    }
pub fn without_modifiers ( & self ) -> ScalarType { use ScalarType :: * ; match self { List { element_type , custom_id : None , } => List { element_type : Box :: new ( element_type . without_modifiers ( ) ) , custom_id : None , } , Map { value_type , custom_id : None , } => Map { value_type : Box :: new ( value_type . without_modifiers ( ) ) , custom_id : None , } , Record { fields , custom_id : None , } => { let fields = fields . iter ( ) . map ( | ( column_name , column_type ) | { ( column_name . clone ( ) , ColumnType { scalar_type : column_type . scalar_type . without_modifiers ( ) , nullable : column_type . nullable , } , ) } ) . collect_vec ( ) ; Record { fields , custom_id : None , } } Array ( a ) => Array ( Box :: new ( a . without_modifiers ( ) ) ) , Numeric { .. } => Numeric { max_scale : None } , // Char's default length should not be `Some(1)`, but instead `None` // to support Char values of different lengths in e.g. lists. Char { .. } => Char { length : None } , VarChar { .. } => VarChar { max_length : None } , v => v . clone ( ) , } }
Returns `self` with any type modifiers removed.
Returns ` self ` with any type modifiers removed .
&self
&self