Unnamed repository; edit this file 'description' to name the repository.
fix: formatting
roife 2024-03-05
parent 16995ce · commit 9cc3a9c
-rw-r--r--crates/hir-ty/src/mir/lower.rs4
-rw-r--r--crates/ide/src/goto_definition.rs2
2 files changed, 4 insertions, 2 deletions
diff --git a/crates/hir-ty/src/mir/lower.rs b/crates/hir-ty/src/mir/lower.rs
index 577a01aee7..d0f739e6ac 100644
--- a/crates/hir-ty/src/mir/lower.rs
+++ b/crates/hir-ty/src/mir/lower.rs
@@ -1366,7 +1366,9 @@ impl<'ctx> MirLowerCtx<'ctx> {
LiteralOrConst::Const(c) => {
let c = match &self.body.pats[*c] {
Pat::Path(p) => p,
- _ => not_supported!("only `char` and numeric types are allowed in range patterns"),
+ _ => not_supported!(
+ "only `char` and numeric types are allowed in range patterns"
+ ),
};
let unresolved_name = || MirLowerError::unresolved_path(self.db, c.as_ref());
let resolver = self.owner.resolver(self.db.upcast());
diff --git a/crates/ide/src/goto_definition.rs b/crates/ide/src/goto_definition.rs
index aac01384cb..1bda15255d 100644
--- a/crates/ide/src/goto_definition.rs
+++ b/crates/ide/src/goto_definition.rs
@@ -536,7 +536,7 @@ fn bar() {
);
}
- #[test]
+ #[test]
fn goto_definition_works_for_consts_inside_range_pattern() {
check(
r#"