pub fn parse_literal<T: FromStr>(&self) -> Option<T> {
        match self {
            Value::Literal(x) => {
                let value = lit_to_string(x);
                T::from_str(&value).ok()
            }
            _ => None,
        }
    }
/// Parses this value into the given type.
///
/// # Returns None
/// - `None` if the value is not a literal.
/// - `None` if the parse fails.
Parses this value into the given type.
Parses this value into the given type .
pub fn parse_literal<T: FromStr>(&self) -> Option<T> {
        match self {
            Value::Literal(x) => {
                let value = lit_to_string(x);
                T::from_str(&value).ok()
            }
            _ => None,
        }
    }
pub fn parse_literal < T : FromStr > ( & self ) -> Option < T > { match self { Value :: Literal ( x ) => { let value = lit_to_string ( x ) ; T :: from_str ( & value ) . ok ( ) } _ => None , } }
Parses this value into the given type.
Parses this value into the given type .
&self
&self
returns none
`None` if the value is not a literal.
`None` if the parse fails.
` None ` if the value is not a literal . ` None ` if the parse fails .