diff options
author | Dmitry <[email protected]> | 2020-08-09 14:35:51 +0100 |
---|---|---|
committer | Dmitry <[email protected]> | 2020-08-09 14:39:32 +0100 |
commit | 8068302fefc75440b823f4bf1731a5f347d7c767 (patch) | |
tree | 251b967182e79bc82a58c2fb208c688f6152df1f /crates/ra_hir/src/code_model.rs | |
parent | 1a43a0f63e0008787225abb6fb2baef97b6a39e0 (diff) | |
parent | 8a57afe5a4bfab40072a83f7dc4ca560bf860919 (diff) |
Merge remote-tracking branch 'origin/master'
Diffstat (limited to 'crates/ra_hir/src/code_model.rs')
-rw-r--r-- | crates/ra_hir/src/code_model.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/crates/ra_hir/src/code_model.rs b/crates/ra_hir/src/code_model.rs index 859bdfb3b..27cdabea0 100644 --- a/crates/ra_hir/src/code_model.rs +++ b/crates/ra_hir/src/code_model.rs | |||
@@ -361,8 +361,8 @@ pub struct Field { | |||
361 | 361 | ||
362 | #[derive(Debug, PartialEq, Eq)] | 362 | #[derive(Debug, PartialEq, Eq)] |
363 | pub enum FieldSource { | 363 | pub enum FieldSource { |
364 | Named(ast::RecordFieldDef), | 364 | Named(ast::RecordField), |
365 | Pos(ast::TupleFieldDef), | 365 | Pos(ast::TupleField), |
366 | } | 366 | } |
367 | 367 | ||
368 | impl Field { | 368 | impl Field { |
@@ -1002,7 +1002,7 @@ impl Local { | |||
1002 | Type::new(db, krate, def, ty) | 1002 | Type::new(db, krate, def, ty) |
1003 | } | 1003 | } |
1004 | 1004 | ||
1005 | pub fn source(self, db: &dyn HirDatabase) -> InFile<Either<ast::BindPat, ast::SelfParam>> { | 1005 | pub fn source(self, db: &dyn HirDatabase) -> InFile<Either<ast::IdentPat, ast::SelfParam>> { |
1006 | let (_body, source_map) = db.body_with_source_map(self.parent.into()); | 1006 | let (_body, source_map) = db.body_with_source_map(self.parent.into()); |
1007 | let src = source_map.pat_syntax(self.pat_id).unwrap(); // Hmm... | 1007 | let src = source_map.pat_syntax(self.pat_id).unwrap(); // Hmm... |
1008 | let root = src.file_syntax(db.upcast()); | 1008 | let root = src.file_syntax(db.upcast()); |