From 139479e8a376aecff35db2055b9ebd2311935f98 Mon Sep 17 00:00:00 2001 From: Veetaha Date: Mon, 10 Feb 2020 01:57:43 +0200 Subject: move to to_usize() --- crates/ra_hir_def/src/body/scope.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'crates/ra_hir_def/src') diff --git a/crates/ra_hir_def/src/body/scope.rs b/crates/ra_hir_def/src/body/scope.rs index a63552327..5d0279945 100644 --- a/crates/ra_hir_def/src/body/scope.rs +++ b/crates/ra_hir_def/src/body/scope.rs @@ -194,7 +194,7 @@ mod tests { let (off, code) = extract_offset(code); let code = { let mut buf = String::new(); - let off = u32::from(off) as usize; + let off = off.to_usize(); buf.push_str(&code[..off]); buf.push_str("marker"); buf.push_str(&code[off..]); -- cgit v1.2.3