(
&mut self,
resolve: &Resolve,
world: WorldId,
funcs: &[(&str, &Function)],
_files: &mut Files,
)
| 631 | } |
| 632 | |
| 633 | fn export_funcs( |
| 634 | &mut self, |
| 635 | resolve: &Resolve, |
| 636 | world: WorldId, |
| 637 | funcs: &[(&str, &Function)], |
| 638 | _files: &mut Files, |
| 639 | ) -> anyhow::Result<()> { |
| 640 | let name = WorldKey::Name(resolve.worlds[world].name.clone()); |
| 641 | let binding = Some(name); |
| 642 | let mut r#gen = self.interface(resolve, binding.as_ref(), false, None); |
| 643 | let namespace = namespace(resolve, &TypeOwner::World(world), true, &r#gen.r#gen.opts); |
| 644 | |
| 645 | for (_name, func) in funcs.iter() { |
| 646 | if matches!(func.kind, FunctionKind::Freestanding) { |
| 647 | r#gen.r#gen.h_src.change_namespace(&namespace); |
| 648 | r#gen.generate_function(func, &TypeOwner::World(world), AbiVariant::GuestExport); |
| 649 | } |
| 650 | } |
| 651 | Ok(()) |
| 652 | } |
| 653 | |
| 654 | fn import_types( |
| 655 | &mut self, |
nothing calls this directly
no test coverage detected