@@ -26,7 +26,7 @@ use wasmtime_core::slab::{Id as SlabId, Slab};
2626use wasmtime_environ:: {
2727 EngineOrModuleTypeIndex , EntityRef , GcLayout , ModuleInternedTypeIndex , ModuleTypes , TypeTrace ,
2828 Undo , VMSharedTypeIndex , WasmRecGroup , WasmSubType ,
29- collections:: { HashSet , PrimaryMap , SecondaryMap , TryClone as _ , Vec } ,
29+ collections:: { HashSet , PrimaryMap , SecondaryMap , TryClone , Vec } ,
3030 iter_entity_range,
3131 packed_option:: { PackedOption , ReservedValue } ,
3232} ;
@@ -285,6 +285,12 @@ impl Clone for RegisteredType {
285285 }
286286}
287287
288+ impl TryClone for RegisteredType {
289+ fn try_clone ( & self ) -> Result < Self , OutOfMemory > {
290+ Ok ( self . clone ( ) )
291+ }
292+ }
293+
288294impl Drop for RegisteredType {
289295 fn drop ( & mut self ) {
290296 self . engine . signatures ( ) . debug_assert_contains ( self . index ) ;
@@ -457,6 +463,12 @@ impl RegisteredType {
457463#[ derive( Clone ) ]
458464struct RecGroupEntry ( Arc < RecGroupEntryInner > ) ;
459465
466+ impl TryClone for RecGroupEntry {
467+ fn try_clone ( & self ) -> Result < Self , OutOfMemory > {
468+ Ok ( self . clone ( ) )
469+ }
470+ }
471+
460472impl Debug for RecGroupEntry {
461473 fn fmt ( & self , f : & mut fmt:: Formatter < ' _ > ) -> fmt:: Result {
462474 struct FormatAsPtr < ' a , P > ( & ' a P ) ;
0 commit comments