Home
last modified time | relevance | path

Searched refs:splitn (Results 1 – 11 of 11) sorted by relevance

/third_party/rust/crates/regex/tests/
Dapi.rs228 splitn!(splitn_below_limit, r"-", r"a", 2, &[t!("a")]);
229 splitn!(splitn_at_limit, r"-", r"a-b", 2, &[t!("a"), t!("b")]);
230 splitn!(splitn_above_limit, r"-", r"a-b-c", 2, &[t!("a"), t!("b-c")]);
231 splitn!(splitn_zero_limit, r"-", r"a-b", 0, empty_vec!());
232 splitn!(splitn_trailing_blank, r"-", r"a-", 2, &[t!("a"), t!("")]);
233 splitn!(splitn_trailing_separator, r"-", r"a--", 2, &[t!("a"), t!("-")]);
234 splitn!(splitn_empty, r"-", r"", 1, &[t!("")]);
Dmacros.rs151 macro_rules! splitn { macro
156 let splitted: Vec<_> = re.splitn(t!($text), $limit).collect();
/third_party/rust/crates/memchr/bench/src/
Dbench.rs37 let mut it = name.splitn(2, "/"); in define()
/third_party/rust/crates/autocfg/src/
Dversion.rs49 let mut iter = version.splitn(3, '.'); in from_rustc()
/third_party/rust/crates/rustix/tests/thread/
Dprctl.rs137 let mut iter = line.splitn(2, '='); in is_linux_kernel_config_item_enabled()
/third_party/rust/crates/rustix/tests/process/
Dprctl.rs204 let mut iter = line.splitn(2, '='); in is_linux_kernel_config_item_enabled()
/third_party/rust/crates/version_check/src/
Dlib.rs110 let split = |s: &str| s.splitn(2, ":").nth(1).map(|s| s.trim().to_string()); in version_and_date_from_rustc_verbose_version()
/third_party/rust/crates/regex/src/
Dre_unicode.rs394 pub fn splitn<'r, 't>( in splitn() method
Dre_bytes.rs341 pub fn splitn<'r, 't>( in splitn() method
/third_party/rust/crates/regex/
DCHANGELOG.md326 Corrects `/-/.splitn("a", 2)` to return `["a"]` instead of `["a", ""]`.
/third_party/rust/crates/memchr/bench/data/code/
Drust-library.rs372 make_test!(splitn_space_char, s, s.splitn(10, ' ').count());
4777 let split: Vec<&str> = data.splitn(4, ' ').collect();
4780 let split: Vec<&str> = data.splitn(4, |c: char| c == ' ').collect();
4784 let split: Vec<&str> = data.splitn(4, 'ä').collect();
4787 let split: Vec<&str> = data.splitn(4, |c: char| c == 'ä').collect();
5451 with str::splitn;
10180 assert_eq!(xs.splitn(1, |x| *x % 2 == 0).collect::<Vec<_>>(), splits);
10182 assert_eq!(xs.splitn(2, |x| *x % 2 == 0).collect::<Vec<_>>(), splits);
10184 assert_eq!(xs.splitn(4, |_| true).collect::<Vec<_>>(), splits);
10188 assert_eq!(xs.splitn(2, |x| *x == 5).collect::<Vec<_>>(), splits);