forked from mirrors/jj
cleanup: fix a few things reported by upgraded rustc and clippy
This commit is contained in:
parent
d961f61623
commit
48b800e5c4
2 changed files with 4 additions and 5 deletions
|
@ -1664,7 +1664,7 @@ fn cmd_evolve<'s>(
|
|||
|
||||
struct Listener<'a, 's> {
|
||||
ui: &'a mut Ui<'s>,
|
||||
};
|
||||
}
|
||||
|
||||
impl<'a, 's> EvolveListener for Listener<'a, 's> {
|
||||
fn orphan_evolved(&mut self, tx: &mut Transaction, orphan: &Commit, new_commit: &Commit) {
|
||||
|
|
|
@ -353,10 +353,9 @@ fn parse_commit_term<'a, 'r: 'a>(
|
|||
None => panic!("if() requires at least two arguments"),
|
||||
Some(pair) => parse_commit_template_rule(repo, pair),
|
||||
};
|
||||
let false_template = match inner.next() {
|
||||
None => None,
|
||||
Some(pair) => Some(parse_commit_template_rule(repo, pair)),
|
||||
};
|
||||
let false_template = inner
|
||||
.next()
|
||||
.map(|pair| parse_commit_template_rule(repo, pair));
|
||||
if inner.next().is_some() {
|
||||
panic!("if() accepts at most three arguments")
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue