Show More
@@ -18,21 +18,19 b' pub fn resolve_single(' | |||
|
18 | 18 | ) -> Result<Revision, RevlogError> { |
|
19 | 19 | let changelog = repo.changelog()?; |
|
20 | 20 | |
|
21 | match resolve_rev_number_or_hex_prefix(input, &changelog.revlog) { | |
|
22 | Err(RevlogError::InvalidRevision) => {} // Try other syntax | |
|
23 | result => return result, | |
|
21 | match input { | |
|
22 | "null" => return Ok(NULL_REVISION), | |
|
23 | _ => {} | |
|
24 | 24 | } |
|
25 | 25 | |
|
26 | if input == "null" { | |
|
27 | return Ok(NULL_REVISION); | |
|
26 | match resolve_rev_number_or_hex_prefix(input, &changelog.revlog) { | |
|
27 | Err(RevlogError::InvalidRevision) => { | |
|
28 | // TODO: support for the rest of the language here. | |
|
29 | let msg = format!("cannot parse revset '{}'", input); | |
|
30 | Err(HgError::unsupported(msg).into()) | |
|
31 | } | |
|
32 | result => return result, | |
|
28 | 33 | } |
|
29 | ||
|
30 | // TODO: support for the rest of the language here. | |
|
31 | ||
|
32 | Err( | |
|
33 | HgError::unsupported(format!("cannot parse revset '{}'", input)) | |
|
34 | .into(), | |
|
35 | ) | |
|
36 | 34 | } |
|
37 | 35 | |
|
38 | 36 | /// Resolve the small subset of the language suitable for revlogs other than |
General Comments 0
You need to be logged in to leave comments.
Login now