pub(crate) fn append_ctype_information(apis: &mut Vec<Api<FnAnalysis>>) {
    let ctypes: HashSet<_> = apis
        .iter()
        .map(|api| api.deps.iter())
        .flatten()
        .filter(|ty| KNOWN_TYPES.is_ctype(ty))
        .cloned()
        .collect();
    for ctype in ctypes {
        let id = make_ident(ctype.get_final_ident());
        apis.push(Api {
            ns: Namespace::new(),
            id: id.clone(),
            deps: HashSet::new(),
            additional_cpp: Some(AdditionalNeed::CTypeTypedef(ctype.clone())),
            detail: ApiDetail::CType,
        });
    }
}
/// Spot any variable-length C types (e.g. unsigned long)
/// used in the [Api]s and append those as extra APIs.
Spot any variable-length C types
used in the [Api]s and append those as extra APIs.
Spot any variable - length C types used in the [ Api ] s and append those as extra APIs .
pub(crate) fn append_ctype_information(apis: &mut Vec<Api<FnAnalysis>>) {
    let ctypes: HashSet<_> = apis
        .iter()
        .map(|api| api.deps.iter())
        .flatten()
        .filter(|ty| KNOWN_TYPES.is_ctype(ty))
        .cloned()
        .collect();
    for ctype in ctypes {
        let id = make_ident(ctype.get_final_ident());
        apis.push(Api {
            ns: Namespace::new(),
            id: id.clone(),
            deps: HashSet::new(),
            additional_cpp: Some(AdditionalNeed::CTypeTypedef(ctype.clone())),
            detail: ApiDetail::CType,
        });
    }
}
pub ( crate ) fn append_ctype_information ( apis : & mut Vec < Api < FnAnalysis > > ) { let ctypes : HashSet < _ > = apis . iter ( ) . map ( | api | api . deps . iter ( ) ) . flatten ( ) . filter ( | ty | KNOWN_TYPES . is_ctype ( ty ) ) . cloned ( ) . collect ( ) ; for ctype in ctypes { let id = make_ident ( ctype . get_final_ident ( ) ) ; apis . push ( Api { ns : Namespace :: new ( ) , id : id . clone ( ) , deps : HashSet :: new ( ) , additional_cpp : Some ( AdditionalNeed :: CTypeTypedef ( ctype . clone ( ) ) ) , detail : ApiDetail :: CType , } ) ; } }
Spot any variable-length C types (e.g.
Spot any variable - length C types ( e . g .
apis
&mut Vec<Api<FnAnalysis>>
apis
&mut Vec<Api<FnAnalysis>>