mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-10-01 14:21:44 +00:00
Cleanup
This commit is contained in:
parent
afce8e4426
commit
d3df80dfe4
7 changed files with 17 additions and 27 deletions
|
@ -76,11 +76,7 @@ impl Body {
|
|||
}
|
||||
|
||||
// needs arbitrary_self_types to be a method... or maybe move to the def?
|
||||
pub fn resolver_for_expr(
|
||||
body: Arc<Body>,
|
||||
db: &impl HirDatabase,
|
||||
expr_id: ExprId,
|
||||
) -> Resolver<'static> {
|
||||
pub fn resolver_for_expr(body: Arc<Body>, db: &impl HirDatabase, expr_id: ExprId) -> Resolver {
|
||||
let scopes = db.expr_scopes(body.owner);
|
||||
resolver_for_scope(body, db, scopes.scope_for(expr_id))
|
||||
}
|
||||
|
@ -89,7 +85,7 @@ pub fn resolver_for_scope(
|
|||
body: Arc<Body>,
|
||||
db: &impl HirDatabase,
|
||||
scope_id: Option<scope::ScopeId>,
|
||||
) -> Resolver<'static> {
|
||||
) -> Resolver {
|
||||
let mut r = body.owner.resolver(db);
|
||||
let scopes = db.expr_scopes(body.owner);
|
||||
let scope_chain = scopes.scope_chain_for(scope_id).collect::<Vec<_>>();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue