pub fn from_ast_lit_str(lit: ast::Lit) -> Option<TokenStream> {
        match lit.node {
            LitKind::Str(val, _) => {
                let val = TokLit::Str_(token::intern(&val));
                Some(TokenStream::from_tts(vec![TokenTree::Token(lit.span,
                                                                 Token::Literal(val, None))]))
            }
            _ => None,
        }

    }
/// Construct a TokenStream from an ast literal.
Construct a TokenStream from an ast literal.
Construct a TokenStream from an ast literal .
pub fn from_ast_lit_str(lit: ast::Lit) -> Option<TokenStream> {
        match lit.node {
            LitKind::Str(val, _) => {
                let val = TokLit::Str_(token::intern(&val));
                Some(TokenStream::from_tts(vec![TokenTree::Token(lit.span,
                                                                 Token::Literal(val, None))]))
            }
            _ => None,
        }
    }
pub fn from_ast_lit_str ( lit : ast :: Lit ) -> Option < TokenStream > { match lit . node { LitKind :: Str ( val , _ ) => { let val = TokLit :: Str_ ( token :: intern ( & val ) ) ; Some ( TokenStream :: from_tts ( vec ! [ TokenTree Token ( lit span Token Literal ( val None ) ) ] ) ) } _ => None , } }
Construct a TokenStream from an ast literal.
Construct a TokenStream from an ast literal .
lit
ast::Lit
lit
ast::Lit