From bf141310f8602a679b8cc3d6318cb9ef5be61c89 Mon Sep 17 00:00:00 2001 From: Vincent Esche Date: Tue, 5 Mar 2024 16:02:22 +0100 Subject: [PATCH] Add `fn index()` accessor for `hir::Param` --- crates/hir/src/lib.rs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/crates/hir/src/lib.rs b/crates/hir/src/lib.rs index ffdf169bbb5..5eed7ecd5b2 100644 --- a/crates/hir/src/lib.rs +++ b/crates/hir/src/lib.rs @@ -2112,6 +2112,10 @@ impl Param { self.func } + pub fn index(&self) -> usize { + self.idx + } + pub fn ty(&self) -> &Type { &self.ty }