linting warning disabled, add all super classes to dependencies
This commit is contained in:
parent
1badd4c698
commit
285ae4b56f
|
@ -846,7 +846,11 @@ pub mod sdk {
|
|||
|
||||
pub fn referenced_types(&self) -> Vec<UObject> {
|
||||
let mut types = Vec::new();
|
||||
self.super_class.map(|obj| types.push(obj.as_uobject()));
|
||||
self.super_class.map(|obj| {
|
||||
types.push(obj.as_uobject());
|
||||
let iter = obj.iter_super_structs();
|
||||
types.extend(iter.map(|strct| strct.as_uobject()));
|
||||
});
|
||||
|
||||
for field in &self.fields {
|
||||
types.extend(field.ty.referenced_type());
|
||||
|
|
|
@ -577,13 +577,13 @@ pub fn generate_package_rust_module<W: Write>(
|
|||
) -> anyhow::Result<()> {
|
||||
writeln!(
|
||||
w,
|
||||
"#![allow(dead_code, non_snake_case, non_camel_case_types)]"
|
||||
"#![allow(dead_code, unused_imports, non_snake_case, non_camel_case_types)]"
|
||||
)?;
|
||||
writeln!(w, "use super::*;")?;
|
||||
for (pkg, _) in &pkg.package_dependencies {
|
||||
writeln!(
|
||||
w,
|
||||
"pub use {}::*;",
|
||||
"use {}::*;",
|
||||
canonicalize_name(&pkg.get_full_name().context("could not get package name")?)
|
||||
)?;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue