1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
use crate::{decl_engine::*, language::ty};
#[derive(Debug, Eq, PartialEq, Hash, Clone)]
pub enum InterfaceDeclId {
Abi(DeclId<ty::TyAbiDeclaration>),
Trait(DeclId<ty::TyTraitDeclaration>),
}
impl From<DeclId<ty::TyAbiDeclaration>> for InterfaceDeclId {
fn from(id: DeclId<ty::TyAbiDeclaration>) -> Self {
Self::Abi(id)
}
}
impl From<DeclId<ty::TyTraitDeclaration>> for InterfaceDeclId {
fn from(id: DeclId<ty::TyTraitDeclaration>) -> Self {
Self::Trait(id)
}
}