mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-10-01 22:31:43 +00:00
Use Local more
This commit is contained in:
parent
31d01efb06
commit
b80fa14a85
4 changed files with 17 additions and 24 deletions
|
@ -195,14 +195,6 @@ impl SourceAnalyzer {
|
|||
Some(self.infer.as_ref()?[pat_id].clone())
|
||||
}
|
||||
|
||||
pub fn type_of_pat_by_id(
|
||||
&self,
|
||||
_db: &impl HirDatabase,
|
||||
pat_id: expr::PatId,
|
||||
) -> Option<crate::Ty> {
|
||||
Some(self.infer.as_ref()?[pat_id].clone())
|
||||
}
|
||||
|
||||
pub fn resolve_method_call(&self, call: &ast::MethodCallExpr) -> Option<Function> {
|
||||
let expr_id = self.expr_id(&call.clone().into())?;
|
||||
self.infer.as_ref()?.method_resolution(expr_id)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue