@@ -2404,31 +2404,48 @@ mod utils {
24042404
24052405 #[ inline]
24062406 pub unsafe fn as_slice( & self , len: usize ) -> & [ T ] {
2407- :: std :: slice:: from_raw_parts( self . as_ptr( ) , len)
2407+ :: $prefix :: slice:: from_raw_parts( self . as_ptr( ) , len)
24082408 }
24092409
24102410 #[ inline]
24112411 pub unsafe fn as_mut_slice( & mut self , len: usize ) -> & mut [ T ] {
2412- :: std :: slice:: from_raw_parts_mut( self . as_mut_ptr( ) , len)
2412+ :: $prefix :: slice:: from_raw_parts_mut( self . as_mut_ptr( ) , len)
24132413 }
24142414 }
24152415 )
24162416 . unwrap ( ) ;
24172417
24182418 let incomplete_array_debug_impl = quote_item ! ( ctx. ext_cx( ) ,
2419- impl <T > :: std :: fmt:: Debug for __IncompleteArrayField<T > {
2420- fn fmt( & self , fmt: & mut :: std :: fmt:: Formatter )
2421- -> :: std :: fmt:: Result {
2419+ impl <T > :: $prefix :: fmt:: Debug for __IncompleteArrayField<T > {
2420+ fn fmt( & self , fmt: & mut :: $prefix :: fmt:: Formatter )
2421+ -> :: $prefix :: fmt:: Result {
24222422 fmt. write_str( "__IncompleteArrayField" )
24232423 }
24242424 }
24252425 )
24262426 . unwrap ( ) ;
24272427
2428+ let incomplete_array_clone_impl = quote_item ! ( & ctx. ext_cx( ) ,
2429+ impl <T > :: $prefix:: clone:: Clone for __IncompleteArrayField<T > {
2430+ #[ inline]
2431+ fn clone( & self ) -> Self {
2432+ Self :: new( )
2433+ }
2434+ }
2435+ )
2436+ . unwrap ( ) ;
2437+
2438+ let incomplete_array_copy_impl = quote_item ! ( & ctx. ext_cx( ) ,
2439+ impl <T > :: $prefix:: marker:: Copy for __IncompleteArrayField<T > { }
2440+ )
2441+ . unwrap ( ) ;
2442+
24282443 let items = vec ! [
24292444 incomplete_array_decl,
24302445 incomplete_array_impl,
24312446 incomplete_array_debug_impl,
2447+ incomplete_array_clone_impl,
2448+ incomplete_array_copy_impl,
24322449 ] ;
24332450
24342451 let old_items = mem:: replace ( result, items) ;
0 commit comments