Rename
This commit is contained in:
parent
b85042601d
commit
9c54537ecf
@ -375,7 +375,7 @@ impl<'db> SemanticsImpl<'db> {
|
||||
}
|
||||
|
||||
pub fn type_of_expr(&self, expr: &ast::Expr) -> Option<Type> {
|
||||
self.analyze(expr.syntax()).type_of(self.db, &expr)
|
||||
self.analyze(expr.syntax()).type_of_expr(self.db, &expr)
|
||||
}
|
||||
|
||||
pub fn type_of_pat(&self, pat: &ast::Pat) -> Option<Type> {
|
||||
|
@ -115,8 +115,7 @@ impl SourceAnalyzer {
|
||||
Some(res)
|
||||
}
|
||||
|
||||
// TODO: rename
|
||||
pub(crate) fn type_of(&self, db: &dyn HirDatabase, expr: &ast::Expr) -> Option<Type> {
|
||||
pub(crate) fn type_of_expr(&self, db: &dyn HirDatabase, expr: &ast::Expr) -> Option<Type> {
|
||||
let expr_id = self.expr_id(db, expr)?;
|
||||
let ty = self.infer.as_ref()?[expr_id].clone();
|
||||
Type::new_with_resolver(db, &self.resolver, ty)
|
||||
|
Loading…
x
Reference in New Issue
Block a user