/external/rust/crates/regex/tests/ |
D | fowler.rs | 5 mat!(match_basic_3, r"abracadabra$", r"abracadabracadabra", Some((7, 18))); 6 mat!(match_basic_4, r"a...b", r"abababbb", Some((2, 7))); 7 mat!(match_basic_5, r"XXXXXX", r"..XXXXXX", Some((2, 8))); 8 mat!(match_basic_6, r"\)", r"()", Some((1, 2))); 9 mat!(match_basic_7, r"a]", r"a]a", Some((0, 2))); 10 mat!(match_basic_9, r"\}", r"}", Some((0, 1))); 11 mat!(match_basic_10, r"\]", r"]", Some((0, 1))); 12 mat!(match_basic_12, r"]", r"]", Some((0, 1))); 13 mat!(match_basic_15, r"^a", r"ax", Some((0, 1))); 14 mat!(match_basic_16, r"\^a", r"a^a", Some((1, 3))); [all …]
|
D | unicode.rs | 1 mat!(uni_literal, r"☃", "☃", Some((0, 3))); 2 mat!(uni_literal_plus, r"☃+", "☃", Some((0, 3))); 3 mat!(uni_literal_casei_plus, r"(?i)☃+", "☃", Some((0, 3))); 4 mat!(uni_class_plus, r"[☃Ⅰ]+", "☃", Some((0, 3))); 5 mat!(uni_one, r"\pN", "Ⅰ", Some((0, 3))); 6 mat!(uni_mixed, r"\pN+", "Ⅰ1Ⅱ2", Some((0, 8))); 7 mat!(uni_not, r"\PN+", "abⅠ", Some((0, 2))); 8 mat!(uni_not_class, r"[\PN]+", "abⅠ", Some((0, 2))); 9 mat!(uni_not_class_neg, r"[^\PN]+", "abⅠ", Some((2, 5))); 10 mat!(uni_case, r"(?i)Δ", "δ", Some((0, 2))); [all …]
|
D | bytes.rs | 14 mat!(word_boundary_unicode, r" \b", " δ", Some((0, 1))); 15 mat!(word_not_boundary, r"(?-u) \B", " δ", Some((0, 1))); 19 mat!(perl_w_ascii, r"(?-u)\w+", "aδ", Some((0, 1))); 21 mat!(perl_w_unicode, r"\w+", "aδ", Some((0, 3))); 22 mat!(perl_d_ascii, r"(?-u)\d+", "1२३9", Some((0, 1))); 24 mat!(perl_d_unicode, r"\d+", "1२३9", Some((0, 8))); 25 mat!(perl_s_ascii, r"(?-u)\s+", " \u{1680}", Some((0, 1))); 27 mat!(perl_s_unicode, r"\s+", " \u{1680}", Some((0, 4))); 36 Some((0, 5)), 37 Some((0, 4)), [all …]
|
D | crazy.rs | 1 mat!(ascii_literal, r"a", "a", Some((0, 1))); 8 Some((5, 8)) 16 mat!(match_float1, r"[-+]?[0-9]*\.?[0-9]+", "0.1", Some((0, 3))); 17 mat!(match_float2, r"[-+]?[0-9]*\.?[0-9]+", "0.1.2", Some((0, 3))); 18 mat!(match_float3, r"[-+]?[0-9]*\.?[0-9]+", "a1.2", Some((1, 4))); 24 Some((8, 26)) 36 Some((8, 26)) 42 Some((0, 10)) 86 mat!(negclass_letters, r"[^ac]", "acx", Some((2, 3))); 87 mat!(negclass_letter_comma, r"[^a,]", "a,x", Some((2, 3))); [all …]
|
D | regression.rs | 30 mat!(regression_unsorted_binary_search_1, r"(?i-u)[a_]+", "A_", Some((0, 2))); 31 mat!(regression_unsorted_binary_search_2, r"(?i-u)[A_]+", "a_", Some((0, 2))); 40 mat!(regression_ascii_word_underscore, r"[[:word:]]", "_", Some((0, 1))); 51 mat!(regression_alt_in_alt1, r"ab?|$", "az", Some((0, 1))); 52 mat!(regression_alt_in_alt2, r"^(.*?)(\n|\r\n?|$)", "ab\rcd", Some((0, 3))); 55 mat!(regression_leftmost_first_prefix, r"z*azb", "azb", Some((0, 3))); 59 mat!(uni_case_lower_nocase_flag, r"(?i)\p{Ll}+", "ΛΘΓΔα", Some((0, 10))); 62 mat!(many_alternates, r"1|2|3|4|5|6|7|8|9|10|int", "int", Some((0, 3))); 106 mat!(lits_unambiguous1, r"(ABC|CDA|BC)X", "CDAX", Some((0, 4))); 113 Some((0, 8)), [all …]
|
/external/rust/crates/bstr/src/search/ |
D | tests.rs | 7 ("", "", Some(0), Some(0)), 8 ("", "a", Some(0), Some(1)), 9 ("", "ab", Some(0), Some(2)), 10 ("", "abc", Some(0), Some(3)), 12 ("a", "a", Some(0), Some(0)), 13 ("a", "aa", Some(0), Some(1)), 14 ("a", "ba", Some(1), Some(1)), 15 ("a", "bba", Some(2), Some(2)), 16 ("a", "bbba", Some(3), Some(3)), 17 ("a", "bbbab", Some(3), Some(3)), [all …]
|
/external/rust/crates/arbitrary/src/ |
D | size_hint.rs | 38 hints.iter().copied().fold((0, Some(0)), and) in and_all() 58 if let Some(head) = hints.first().copied() { in or_all() 61 (0, Some(0)) in or_all() 69 assert_eq!((5, Some(5)), super::and((2, Some(2)), (3, Some(3)))); in and() 70 assert_eq!((5, None), super::and((2, Some(2)), (3, None))); in and() 71 assert_eq!((5, None), super::and((2, None), (3, Some(3)))); in and() 77 assert_eq!((2, Some(3)), super::or((2, Some(2)), (3, Some(3)))); in or() 78 assert_eq!((2, None), super::or((2, Some(2)), (3, None))); in or() 79 assert_eq!((2, None), super::or((2, None), (3, Some(3)))); in or() 85 assert_eq!((0, Some(0)), super::and_all(&[])); in and_all() [all …]
|
/external/rust/crates/unicode-width/src/ |
D | tests.rs | 75 Some(1) in simple_width_if() 77 Some(0) in simple_width_if() 90 cu if cu == 0 => Some(0), in simple_width_match() 92 cu if cu < 0x7f => Some(1), in simple_width_match() 125 use core::option::Option::{Some, None}; in test_char() 127 assert_eq!(UnicodeWidthChar::width('h'), Some(2)); in test_char() 128 assert_eq!('h'.width_cjk(), Some(2)); in test_char() 129 assert_eq!(UnicodeWidthChar::width('\x00'), Some(0)); in test_char() 130 assert_eq!('\x00'.width_cjk(), Some(0)); in test_char() 133 assert_eq!(UnicodeWidthChar::width('\u{2081}'), Some(1)); in test_char() [all …]
|
/external/rust/crates/managed/src/ |
D | map.rs | 74 Some(T), enumerator 81 Some(x) => RevOption::Some(x), in from() 90 RevOption::Some(x) => Some(x), in into() 120 Some((ref k, ref v)) => Some((k, v)) in next() 140 Some((ref k, ref v)) => Some((k, v)) in next_back() 175 Bound::Included(ref key_begin) => $item < Some(key_begin.borrow()), in binary_search_by_key_range() 176 Bound::Excluded(ref key_begin) => $item <= Some(key_begin.borrow()), in binary_search_by_key_range() 206 Bound::Included(ref key_end) => $item > Some(key_end.borrow()), in binary_search_by_key_range() 207 Bound::Excluded(ref key_end) => $item >= Some(key_end.borrow()), in binary_search_by_key_range() 236 slice.binary_search_by_key(&RevOption::Some(key), |entry| { in binary_search_by_key() [all …]
|
/external/rust/crates/itertools/tests/ |
D | tuples.rs | 7 assert_eq!(Some((1,)), iter.next()); in tuples() 8 assert_eq!(Some((2,)), iter.next()); in tuples() 9 assert_eq!(Some((3,)), iter.next()); in tuples() 10 assert_eq!(Some((4,)), iter.next()); in tuples() 11 assert_eq!(Some((5,)), iter.next()); in tuples() 16 assert_eq!(Some((1, 2)), iter.next()); in tuples() 17 assert_eq!(Some((3, 4)), iter.next()); in tuples() 22 assert_eq!(Some((1, 2, 3)), iter.next()); in tuples() 27 assert_eq!(Some((1, 2, 3, 4)), iter.next()); in tuples() 37 assert_eq!(Some((1,)), iter.next()); in tuple_windows() [all …]
|
/external/rust/crates/protobuf-codegen/src/ |
D | customize.rs | 53 if let Some(v) = that.expose_oneof { in update_with() 54 self.expose_oneof = Some(v); in update_with() 56 if let Some(v) = that.expose_fields { in update_with() 57 self.expose_fields = Some(v); in update_with() 59 if let Some(v) = that.generate_accessors { in update_with() 60 self.generate_accessors = Some(v); in update_with() 62 if let Some(v) = that.carllerche_bytes_for_bytes { in update_with() 63 self.carllerche_bytes_for_bytes = Some(v); in update_with() 65 if let Some(v) = that.carllerche_bytes_for_string { in update_with() 66 self.carllerche_bytes_for_string = Some(v); in update_with() [all …]
|
/external/adhd/cras/client/cras_tests/src/ |
D | arguments.rs | 65 Some("help") => { in parse() 69 Some("capture") => Ok( in parse() 72 Some("playback") => Ok( in parse() 76 Some("control") => { in parse() 79 Some(s) => { in parse() 194 Some("pre_dsp") => Some(LoopbackType::PreDsp), in parse() 195 Some("post_dsp") => Some(LoopbackType::PostDsp), in parse() 196 Some(s) => { in parse() 214 Some(file_name) => PathBuf::from(file_name), in parse() 221 Some("wav") | Some("wave") => FileType::Wav, in parse() [all …]
|
/external/rust/crates/itertools/src/ |
D | merge_join.rs | 63 (Some(left), None) => in next() 64 Some(EitherOrBoth::Left(left)), in next() 65 (None, Some(right)) => in next() 66 Some(EitherOrBoth::Right(right)), in next() 67 (Some(left), Some(right)) => { in next() 70 Some(EitherOrBoth::Both(left, right)), in next() 73 Some(EitherOrBoth::Left(left)) in next() 77 Some(EitherOrBoth::Right(right)) in next() 91 (Some(x), Some(y)) => x.checked_add(y), in size_hint() 103 (Some(_left), None) => break count + 1 + self.left.into_parts().1.count(), in count() [all …]
|
/external/rust/crates/shlex/src/ |
D | lib.rs | 54 '\\' => if let Some(ch2) = self.next_char() { in parse_word() 63 if let Some(ch2) = self.next_char() { ch = ch2; } else { break; } in parse_word() 65 unsafe { Some(String::from_utf8_unchecked(result)) } in parse_word() 70 if let Some(ch2) = self.next_char() { in parse_double() 73 if let Some(ch3) = self.next_char() { in parse_double() 97 if let Some(ch2) = self.next_char() { in parse_single() 110 if res == Some('\n' as u8) { self.line_no += 1; } in next_char() 118 if let Some(mut ch) = self.next_char() { in next() 124 while let Some(ch2) = self.next_char() { in next() 130 if let Some(ch2) = self.next_char() { ch = ch2; } else { return None; } in next() [all …]
|
/external/rust/crates/plotters/src/coord/ranged1d/combinators/ |
D | linspace.rs | 44 values[0].partial_cmp(&values[1]) == Some(Ordering::Less) in search() 54 Ok(idx) => Some(idx), in search() 61 Some(idx - offset) in search() 77 values[0].partial_cmp(&values[1]) == Some(Ordering::Less) in search() 87 Ok(idx) => Some(idx), in search() 94 Some(idx - offset) in search() 114 values[0].partial_cmp(&values[1]) == Some(Ordering::Less) in search() 124 Ok(idx) => Some(idx), in search() 127 return Some(0); in search() 131 return Some(idx - 1); in search() [all …]
|
/external/rust/cxx/syntax/ |
D | check.rs | 110 None | Some(Char) | Some(U8) | Some(U16) | Some(U32) | Some(U64) | Some(Usize) in check_type_rust_vec() 111 | Some(I8) | Some(I16) | Some(I32) | Some(I64) | Some(Isize) | Some(F32) in check_type_rust_vec() 112 | Some(F64) | Some(RustString) => return, in check_type_rust_vec() 113 Some(Bool) => { /* todo */ } in check_type_rust_vec() 114 Some(CxxString) => {} in check_type_rust_vec() 132 None | Some(CxxString) => return, in check_type_unique_ptr() 150 None | Some(Bool) | Some(U8) | Some(U16) | Some(U32) | Some(U64) | Some(Usize) in check_type_shared_ptr() 151 | Some(I8) | Some(I16) | Some(I32) | Some(I64) | Some(Isize) | Some(F32) in check_type_shared_ptr() 152 | Some(F64) | Some(CxxString) => return, in check_type_shared_ptr() 153 Some(Char) | Some(RustString) => {} in check_type_shared_ptr() [all …]
|
D | error.rs | 32 note: Some("hint: use UniquePtr<> or SharedPtr<>"), 37 label: Some("reserved identifier"), 38 note: Some("identifiers starting with cxxbridge are reserved"), 44 note: Some("hint: wrap it in a UniquePtr<>"), 50 note: Some("hint: wrap it in a UniquePtr<> or SharedPtr<>"), 55 label: Some("discriminant overflow"), 56 note: Some("note: explicitly set `= 0` if that is desired outcome"), 61 label: Some("#include relative to `.` or `..` is not supported in Cargo builds"), 62 note: Some("note: use a path starting with the crate name"), 67 label: Some("reserved identifier"), [all …]
|
D | atom.rs | 33 "bool" => Some(Bool), in from_str() 34 "c_char" => Some(Char), in from_str() 35 "u8" => Some(U8), in from_str() 36 "u16" => Some(U16), in from_str() 37 "u32" => Some(U32), in from_str() 38 "u64" => Some(U64), in from_str() 39 "usize" => Some(Usize), in from_str() 40 "i8" => Some(I8), in from_str() 41 "i16" => Some(I16), in from_str() 42 "i32" => Some(I32), in from_str() [all …]
|
/external/rust/crates/macaddr/src/parser/ |
D | mod.rs | 87 Some(self.source[self.pos] as char) in peek_char() 114 Some('-') if self.delimiter.is_none() => { in probe_delimiter() 115 self.delimiter = Some(Delimiter::Hyphen); in probe_delimiter() 116 Ok(Some(())) in probe_delimiter() 118 …Some('-') if self.delimiter != Some(Delimiter::Hyphen) => Err(ParseError::InvalidCharacter('-', se… in probe_delimiter() 119 Some('-') => Ok(Some(())), in probe_delimiter() 121 Some(':') if self.delimiter.is_none() => { in probe_delimiter() 122 self.delimiter = Some(Delimiter::Colon); in probe_delimiter() 123 Ok(Some(())) in probe_delimiter() 125 …Some(':') if self.delimiter != Some(Delimiter::Colon) => Err(ParseError::InvalidCharacter(':', sel… in probe_delimiter() [all …]
|
/external/rust/crates/structopt/tests/ |
D | options.rs | 44 Opt { arg: Some(42) }, in optional_option() 149 assert_eq!(Opt { a: Some(A) }, Opt::from_iter(&["test", "foo"])); in option_from_str() 162 arg: Some(Some(42)) in optional_argument_for_optional_option() 167 Opt { arg: Some(None) }, in optional_argument_for_optional_option() 192 arg: Some(Some(42)), in two_option_options() 193 field: Some(Some("f".into())) in two_option_options() 199 arg: Some(Some(42)), in two_option_options() 200 field: Some(None) in two_option_options() 206 arg: Some(None), in two_option_options() 207 field: Some(None) in two_option_options() [all …]
|
/external/llvm/unittests/IR/ |
D | ConstantRangeTest.cpp | 24 static ConstantRange Some; member in __anon23360c560111::ConstantRangeTest 31 ConstantRange ConstantRangeTest::Some(APInt(16, 0xa), APInt(16, 0xaaa)); member in __anon23360c560111::ConstantRangeTest 65 EXPECT_FALSE(Some.isFullSet()); in TEST_F() 66 EXPECT_FALSE(Some.isEmptySet()); in TEST_F() 67 EXPECT_FALSE(Some.isWrappedSet()); in TEST_F() 68 EXPECT_FALSE(Some.contains(APInt(16, 0x0))); in TEST_F() 69 EXPECT_FALSE(Some.contains(APInt(16, 0x9))); in TEST_F() 70 EXPECT_TRUE(Some.contains(APInt(16, 0xa))); in TEST_F() 71 EXPECT_TRUE(Some.contains(APInt(16, 0xaa9))); in TEST_F() 72 EXPECT_FALSE(Some.contains(APInt(16, 0xaaa))); in TEST_F() [all …]
|
/external/rust/crates/proc-macro2/src/ |
D | parse.rs | 147 Some(ch) if is_ident_continue(ch) => Err(Reject), in word_break() 148 Some(_) | None => Ok(input), in word_break() 169 Some(first) => first, in token_stream() 173 Some((lo, _frame)) => { in token_stream() 179 Some(_frame) => return Err(LexError { span: Span {} }), in token_stream() 183 if let Some(open_delimiter) = match first { in token_stream() 184 b'(' => Some(Delimiter::Parenthesis), in token_stream() 185 b'[' => Some(Delimiter::Bracket), in token_stream() 186 b'{' => Some(Delimiter::Brace), in token_stream() 195 } else if let Some(close_delimiter) = match first { in token_stream() [all …]
|
/external/rust/crates/clap/src/args/ |
D | arg.rs | 377 self.s.long = Some(l.trim_left_matches(|c| c == '-')); in long() 403 if let Some(ref mut als) = self.s.aliases { in alias() 406 self.s.aliases = Some(vec![(name.into(), false)]); in alias() 433 if let Some(ref mut als) = self.s.aliases { in aliases() 438 self.s.aliases = Some(names.iter().map(|n| (*n, false)).collect::<Vec<_>>()); in aliases() 464 if let Some(ref mut als) = self.s.aliases { in visible_alias() 467 self.s.aliases = Some(vec![(name.into(), true)]); in visible_alias() 491 if let Some(ref mut als) = self.s.aliases { in visible_aliases() 496 self.s.aliases = Some(names.iter().map(|n| (*n, true)).collect::<Vec<_>>()); in visible_aliases() 552 self.b.help = Some(h); in help() [all …]
|
/external/rust/crates/crossbeam-deque/tests/ |
D | steal.rs | 53 assert_eq!(w2.pop(), Some(1)); in steal_batch_fifo_fifo() 54 assert_eq!(w2.pop(), Some(2)); in steal_batch_fifo_fifo() 68 assert_eq!(w2.pop(), Some(2)); in steal_batch_lifo_lifo() 69 assert_eq!(w2.pop(), Some(1)); in steal_batch_lifo_lifo() 83 assert_eq!(w2.pop(), Some(1)); in steal_batch_fifo_lifo() 84 assert_eq!(w2.pop(), Some(2)); in steal_batch_fifo_lifo() 98 assert_eq!(w2.pop(), Some(2)); in steal_batch_lifo_fifo() 99 assert_eq!(w2.pop(), Some(1)); in steal_batch_lifo_fifo() 111 assert_eq!(w2.pop(), Some(1)); in steal_batch_injector_fifo() 112 assert_eq!(w2.pop(), Some(2)); in steal_batch_injector_fifo() [all …]
|
/external/rust/crates/chrono/src/naive/ |
D | date.rs | 141 Some(NaiveDate { ymdf: (year << 13) | (of as DateImpl) }) in from_of() 790 Some(NaiveDate { ymdf: (self.ymdf & !0b1_1111_1111_1111) | of as DateImpl }) in with_of() 1008 DelayedFormat::new(Some(*self), None, items) in format_with_items() 1577 Some(current) in next() 1582 (exact_size as usize, Some(exact_size as usize)) in size_hint() 1602 Some(current) in next() 1607 (exact_size as usize, Some(exact_size as usize)) in size_hint() 1723 assert_eq!(to_string(&NaiveDate::from_ymd(2014, 7, 24)).ok(), Some(r#""2014-07-24""#.into())); in test_encodable_json() 1724 assert_eq!(to_string(&NaiveDate::from_ymd(0, 1, 1)).ok(), Some(r#""0000-01-01""#.into())); in test_encodable_json() 1725 assert_eq!(to_string(&NaiveDate::from_ymd(-1, 12, 31)).ok(), Some(r#""-0001-12-31""#.into())); in test_encodable_json() [all …]
|