RemoveDeadCode

This commit is contained in:
Aleksey Kladov 2018-10-31 23:50:18 +03:00
parent 6be50f7d5d
commit 8f1a83b4cb
1 changed files with 0 additions and 17 deletions

View File

@ -39,23 +39,6 @@ impl SyntaxPtr {
}
}
struct OwnedAst<T> {
syntax: SyntaxNode,
phantom: PhantomData<T>,
}
trait ToAst {
type Ast;
fn to_ast(self) -> Self::Ast;
}
impl<'a> ToAst for &'a OwnedAst<ast::FnDef<'static>> {
type Ast = ast::FnDef<'a>;
fn to_ast(self) -> ast::FnDef<'a> {
ast::FnDef::cast(self.syntax.borrowed()).unwrap()
}
}
/// A pionter to a syntax node inside a file.
#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
pub(crate) struct LocalSyntaxPtr {