Skip to content

Commit 03577a9

Browse files
committed
Fix some clippy warnings
1 parent ec8cd6d commit 03577a9

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/eval_context.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1680,12 +1680,12 @@ pub fn eval_main<'a, 'tcx: 'a>(
16801680
}
16811681
}
16821682
Err(e) => {
1683-
report(tcx, &ecx, e);
1683+
report(tcx, &ecx, &e);
16841684
}
16851685
}
16861686
}
16871687

1688-
fn report(tcx: TyCtxt, ecx: &EvalContext, e: EvalError) {
1688+
fn report(tcx: TyCtxt, ecx: &EvalContext, e: &EvalError) {
16891689
if let Some(frame) = ecx.stack().last() {
16901690
let block = &frame.mir.basic_blocks()[frame.block];
16911691
let span = if frame.stmt < block.statements.len() {

tests/run-pass/union.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ fn c() {
6262
unsafe {
6363
match v {
6464
Value { tag: Tag::I, u: U { i: 0 } } => true,
65-
Value { tag: Tag::F, u: U { f } } if f == 0.0 => true,
65+
Value { tag: Tag::F, u: U { f } } => f == 0.0,
6666
_ => false,
6767
}
6868
}

0 commit comments

Comments
 (0)