Searched refs:collect_lines (Results 1 – 1 of 1) sorted by relevance
/external/rust/crates/bstr/src/ |
D | io.rs | 446 fn collect_lines<B: AsRef<[u8]>>(slice: B) -> Vec<BString> { in collect_lines() function 472 assert_eq!(collect_lines(""), Vec::<BString>::new()); in lines_without_terminator() 474 assert_eq!(collect_lines("\n"), vec![""]); in lines_without_terminator() 475 assert_eq!(collect_lines("\n\n"), vec!["", ""]); in lines_without_terminator() 476 assert_eq!(collect_lines("a\nb\n"), vec!["a", "b"]); in lines_without_terminator() 477 assert_eq!(collect_lines("a\nb"), vec!["a", "b"]); in lines_without_terminator() 478 assert_eq!(collect_lines("abc\nxyz\n"), vec!["abc", "xyz"]); in lines_without_terminator() 479 assert_eq!(collect_lines("abc\nxyz"), vec!["abc", "xyz"]); in lines_without_terminator() 481 assert_eq!(collect_lines("\r\n"), vec![""]); in lines_without_terminator() 482 assert_eq!(collect_lines("\r\n\r\n"), vec!["", ""]); in lines_without_terminator() [all …]
|