@@ -142,16 +142,16 @@ impl<'a> ModuleAdapter<'a> {
142142 let mut func = wasm_encoder:: Function :: new ( std:: iter:: empty ( ) ) ;
143143
144144 for i in 0 ..info. import_type . params . len ( ) as u32 {
145- func. instruction ( wasm_encoder:: Instruction :: LocalGet ( i) ) ;
145+ func. instruction ( & wasm_encoder:: Instruction :: LocalGet ( i) ) ;
146146 }
147147
148- func. instruction ( wasm_encoder:: Instruction :: I32Const ( func_index as i32 ) ) ;
149- func. instruction ( wasm_encoder:: Instruction :: CallIndirect {
148+ func. instruction ( & wasm_encoder:: Instruction :: I32Const ( func_index as i32 ) ) ;
149+ func. instruction ( & wasm_encoder:: Instruction :: CallIndirect {
150150 ty : * type_index,
151151 table : 0 ,
152152 } ) ;
153153
154- func. instruction ( wasm_encoder:: Instruction :: End ) ;
154+ func. instruction ( & wasm_encoder:: Instruction :: End ) ;
155155
156156 code. function ( & func) ;
157157 }
@@ -170,10 +170,8 @@ impl<'a> ModuleAdapter<'a> {
170170
171171 tables. table ( wasm_encoder:: TableType {
172172 element_type : wasm_encoder:: ValType :: FuncRef ,
173- limits : wasm_encoder:: Limits {
174- min : table_len,
175- max : Some ( table_len) ,
176- } ,
173+ minimum : table_len,
174+ maximum : Some ( table_len) ,
177175 } ) ;
178176
179177 exports. export ( FUNCTION_TABLE_NAME , wasm_encoder:: Export :: Table ( 0 ) ) ;
@@ -300,7 +298,9 @@ impl<'a> ModuleAdapter<'a> {
300298 PARENT_MODULE_NAME ,
301299 Some ( MEMORY_EXPORT_NAME ) ,
302300 wasm_encoder:: EntityType :: Memory ( wasm_encoder:: MemoryType {
303- limits : wasm_encoder:: Limits { min : 0 , max : None } ,
301+ maximum : None ,
302+ minimum : 0 ,
303+ memory64 : false ,
304304 } ) ,
305305 ) ;
306306
0 commit comments