fn to_mangled(namespace: &Namespace, ty: &Type) -> String {
    match ty {
        Type::Ident(_) => to_typename(namespace, ty).replace("::", "$"),
        Type::CxxVector(ptr) => format!("std$vector${}", to_mangled(namespace, &ptr.inner)),
        _ => unreachable!(),
    }
}
// Only called for legal referent types of unique_ptr and element types of
// std::vector and Vec.
Only called for legal referent types of unique_ptr and element types of
std::vector and Vec.
Only called for legal referent types of unique_ptr and element types of std :: vector and Vec .
fn to_mangled(namespace: &Namespace, ty: &Type) -> String {
    match ty {
        Type::Ident(_) => to_typename(namespace, ty).replace("::", "$"),
        Type::CxxVector(ptr) => format!("std$vector${}", to_mangled(namespace, &ptr.inner)),
        _ => unreachable!(),
    }
}
fn to_mangled ( namespace : & Namespace , ty : & Type ) -> String { match ty { Type :: Ident ( _ ) => to_typename ( namespace , ty ) . replace ( " " , " " ) , Type :: CxxVector ( ptr ) => format ! ( " " to_mangled ( namespace ptr inner ) ) , _ => unreachable ! ( ) , } }
Only called for legal referent types of unique_ptr and element types of
std::vector and Vec.
Only called for legal referent types of unique_ptr and element types of std :: vector and Vec .
namespace
&Namespace
ty
&Type
namespace
&Namespace
ty
&Type