File tree Expand file tree Collapse file tree 1 file changed +2
-19
lines changed
Expand file tree Collapse file tree 1 file changed +2
-19
lines changed Original file line number Diff line number Diff line change @@ -169,28 +169,11 @@ pub fn differential_execution(
169169 }
170170 } ;
171171
172- let funcs = module
173- . exports ( )
174- . filter_map ( |e| {
175- if let ExternType :: Func ( _) = e. ty ( ) {
176- Some ( e. name ( ) )
177- } else {
178- None
179- }
180- } )
181- . collect :: < Vec < _ > > ( ) ;
182-
183- for name in funcs {
172+ for f in module. exports ( ) . filter_map ( |e| e. into_func ( ) ) {
184173 // Always call the hang limit initializer first, so that we don't
185174 // infinite loop when calling another export.
186175 init_hang_limit ( & instance) ;
187176
188- let f = instance
189- . get_export ( & name)
190- . expect ( "instance should have export from module" )
191- . into_func ( )
192- . expect ( "export should be a function" ) ;
193-
194177 let ty = f. ty ( ) ;
195178 let params = match dummy:: dummy_values ( ty. params ( ) ) {
196179 Ok ( p) => p,
@@ -375,7 +358,7 @@ pub fn make_api_calls(api: crate::generators::api::ApiCalls) {
375358
376359 let funcs = instance
377360 . exports ( )
378- . filter_map ( |e| match e {
361+ . filter_map ( |e| match e. into_extern ( ) {
379362 Extern :: Func ( f) => Some ( f. clone ( ) ) ,
380363 _ => None ,
381364 } )
You can’t perform that action at this time.
0 commit comments