File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -41,15 +41,20 @@ macro_rules! pre_emit {
4141 } ;
4242 ( $( $_: tt) * ) => { } ;
4343}
44+
45+ // TODO: remove the mannually written Label conversions. These can be auto-generated by
46+ // changing the base class of AssocItem from AstNode to Item
4447impl From < crate :: trap:: Label < generated:: AssocItem > > for crate :: trap:: Label < generated:: Item > {
4548 fn from ( value : crate :: trap:: Label < generated:: AssocItem > ) -> Self {
46- // SAFETY: this is safe because in the dbscheme Item is a subclass of Stmt
49+ // SAFETY: this is safe because every concrete instance of `@assoc_item` is also an instance of `@item`
4750 unsafe { Self :: from_untyped ( value. as_untyped ( ) ) }
4851 }
4952}
53+ // TODO: remove the mannually written Label conversions. These can be auto-generated by
54+ // changing the base class of ExternItem from AstNode to Item
5055impl From < crate :: trap:: Label < generated:: ExternItem > > for crate :: trap:: Label < generated:: Item > {
5156 fn from ( value : crate :: trap:: Label < generated:: ExternItem > ) -> Self {
52- // SAFETY: this is safe because in the dbscheme Item is a subclass of Stmt
57+ // SAFETY: this is safe because every concrete instance of `@extern_item` is also an instance of `@item`
5358 unsafe { Self :: from_untyped ( value. as_untyped ( ) ) }
5459 }
5560}
You can’t perform that action at this time.
0 commit comments