You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
name = name.strip_suffix(b" ").unwrap_or(name).as_bstr();
98
+
99
+
let email = i[left_delim_idx + skip_from_left..right_delim_idx - skip_from_right].as_bstr();
100
+
*i = i.get(right_delim_idx + 1..).unwrap_or(&[]);
101
+
Ok(IdentityRef{ name, email })
77
102
}
78
103
}
79
104
pubuse function::identity;
@@ -167,7 +192,7 @@ mod tests {
167
192
.map_err(to_bstr_err)
168
193
.expect_err("parse fails as > is missing")
169
194
.to_string(),
170
-
"in slice at '12345 -1215'\n 0: expected `<email>` at ' 12345 -1215'\n 1: expected `<name> <<email>>` at 'hello < 12345 -1215'\n2: expected `<name> <<email>> <timestamp> <+|-><HHMM>` at 'hello < 12345 -1215'\n"
195
+
"in end of file at 'hello < 12345 -1215'\n 0: invalid Closing '>' not found at 'hello < 12345 -1215'\n1: expected `<name> <<email>> <timestamp> <+|-><HHMM>` at 'hello < 12345 -1215'\n"
0 commit comments