We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6699c90 commit e58b683Copy full SHA for e58b683
Cargo.toml
@@ -176,7 +176,6 @@ forget_non_drop = "allow"
176
format_collect = "allow"
177
large_enum_variant = "allow"
178
needless_doctest_main = "allow"
179
-needless_return = "allow"
180
new_without_default = "allow"
181
nonminimal_bool = "allow"
182
non_canonical_clone_impl = "allow"
crates/hir/src/lib.rs
@@ -2404,10 +2404,10 @@ impl Const {
2404
}
2405
2406
if let Ok(s) = mir::render_const_using_debug_impl(db, self.id, &c) {
2407
- return Ok(s);
+ Ok(s)
2408
+ } else {
2409
+ Ok(format!("{}", c.display(db)))
2410
- let r = format!("{}", c.display(db));
- return Ok(r);
2411
2412
2413
0 commit comments