• Home
  • Raw
  • Download

Lines Matching refs:TokenStream

8 use proc_macro2::{Ident, Literal, Punct, Spacing, Span, TokenStream, TokenTree};
107 "\"\\\r\n x\"".parse::<TokenStream>().unwrap(); in literal_string()
108 "\"\\\r\n \rx\"".parse::<TokenStream>().unwrap_err(); in literal_string()
113 "r\"\r\n\"".parse::<TokenStream>().unwrap(); in literal_raw_string()
126 .parse::<TokenStream>() in literal_raw_string()
131 .parse::<TokenStream>() in literal_raw_string()
147 "b\"\\\r\n x\"".parse::<TokenStream>().unwrap(); in literal_byte_string()
148 "b\"\\\r\n \rx\"".parse::<TokenStream>().unwrap_err(); in literal_byte_string()
149 "b\"\\\r\n \u{a0}x\"".parse::<TokenStream>().unwrap_err(); in literal_byte_string()
150 "br\"\u{a0}\"".parse::<TokenStream>().unwrap_err(); in literal_byte_string()
162 let mut tokens = strings.parse::<TokenStream>().unwrap().into_iter(); in literal_c_string()
183 if let Ok(unexpected) = invalid.parse::<TokenStream>() { in literal_c_string()
239 p.parse::<TokenStream>().unwrap().into_iter().count() in literal_suffix()
265 let tokens = TokenStream::from(TokenTree::Literal(negative_literal)); in literal_iter_negative()
333 .parse::<proc_macro2::TokenStream>() in source_text()
350 let s = p.parse::<TokenStream>().unwrap().to_string(); in roundtrip()
352 let s2 = s.parse::<TokenStream>().unwrap().to_string(); in roundtrip()
388 if let Ok(s) = p.parse::<TokenStream>() { in fail()
451 .parse::<TokenStream>() in span_join()
456 .parse::<TokenStream>() in span_join()
488 assert!(s.parse::<TokenStream>().is_err()); in no_panic()
493 let mut tts = TokenStream::from_str("~// comment").unwrap().into_iter(); in punct_before_comment()
511 let stream = TokenStream::from(TokenTree::Punct(joint_punct)); in joint_last_token()
521 let mut tts = TokenStream::from_str("r#dyn").unwrap().into_iter(); in raw_identifier()
544 let tts = TokenStream::from_str("[a + 1]").unwrap(); in test_debug_tokenstream()
648 let default_token_stream = <TokenStream as Default>::default(); in default_tokenstream_is_empty()
655 let tokens = "a b (c d) e".parse::<TokenStream>().unwrap(); in tokenstream_size_hint()
663 let mut tokens = "tuple.0.0".parse::<TokenStream>().unwrap().into_iter(); in tuple_indexing()
710 let ts = p.parse::<TokenStream>().unwrap(); in check_spans()
716 fn check_spans_internal(ts: TokenStream, lines: &mut &[(usize, usize, usize, usize)]) { in check_spans_internal() argument
741 let tokens = various_spaces.parse::<TokenStream>().unwrap(); in whitespace()
745 lone_carriage_returns.parse::<TokenStream>().unwrap(); in whitespace()
751 let tokens = string.parse::<TokenStream>().unwrap(); in byte_order_mark()
758 string.parse::<TokenStream>().unwrap_err(); in byte_order_mark()