+ if let syn::Type::Tuple(syn::TypeTuple { elems, .. }) = t {
+ assert!(elems.is_empty());
+ let inner_name = self.get_c_mangled_container_type(vec![single_contained.unwrap()], generics, "Option").unwrap();
+ return Some(("if ", vec![
+ (format!(".is_none() {{ {}::None }} else {{ {}::Some /*",
+ inner_name, inner_name), format!(""))
+ ], " */}", ContainerPrefixLocation::PerConv));
+ }
+ if let syn::Type::Reference(syn::TypeReference { elem, .. }) = t {
+ if let syn::Type::Slice(_) = &**elem {
+ return Some(("if ", vec![
+ (".is_none() { SmartPtr::null() } else { SmartPtr::from_obj(".to_string(),
+ format!("({}.unwrap())", var_access))
+ ], ") }", ContainerPrefixLocation::PerConv));
+ }
+ }