Unnamed repository; edit this file 'description' to name the repository.
Diffstat (limited to 'crates/hir-expand/src/ast_id_map.rs')
| -rw-r--r-- | crates/hir-expand/src/ast_id_map.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/crates/hir-expand/src/ast_id_map.rs b/crates/hir-expand/src/ast_id_map.rs index 02efaace43..c2b0d5985e 100644 --- a/crates/hir-expand/src/ast_id_map.rs +++ b/crates/hir-expand/src/ast_id_map.rs @@ -20,7 +20,7 @@ use syntax::{ast, AstNode, AstPtr, SyntaxNode, SyntaxNodePtr}; /// `AstId` points to an AST node in a specific file. pub struct FileAstId<N: AstNode> { raw: ErasedFileAstId, - _ty: PhantomData<fn() -> N>, + covariant: PhantomData<fn() -> N>, } impl<N: AstNode> Clone for FileAstId<N> { @@ -54,7 +54,7 @@ impl<N: AstNode> FileAstId<N> { where N: Into<M>, { - FileAstId { raw: self.raw, _ty: PhantomData } + FileAstId { raw: self.raw, covariant: PhantomData } } } @@ -122,7 +122,7 @@ impl AstIdMap { pub fn ast_id<N: AstNode>(&self, item: &N) -> FileAstId<N> { let raw = self.erased_ast_id(item.syntax()); - FileAstId { raw, _ty: PhantomData } + FileAstId { raw, covariant: PhantomData } } pub fn get<N: AstNode>(&self, id: FileAstId<N>) -> AstPtr<N> { |