Skip to main content

Module functions

Module functions 

Source

Functions§

collect_explicit_core_imports
Collect explicit type and enum names from the API surface for named imports.
collect_trait_imports
Collect all unique trait import paths from types’ methods.
gen_function
Generate a free function. Equivalent to gen_function_with_mutex with no mutex types.
gen_function_with_mutex
Generate a free function. mutex_types is the subset of opaque types whose inner field is Arc<Mutex<T>> (because the type has &mut self methods); their constructors emit Arc::new(Mutex::new(v)) instead of Arc::new(v).
has_unresolved_trait_methods
Check if any type has methods from trait impls whose trait_source could not be resolved.