Home
last modified time | relevance | path

Searched refs:RustString (Results 1 – 11 of 11) sorted by relevance

/external/rust/cxx/src/
Drust_string.rs10 pub struct RustString { struct
14 impl RustString { argument
16 unsafe { mem::transmute::<String, RustString>(s) } in from()
20 unsafe { &*(s as *const String as *const RustString) } in from_ref() constant
24 unsafe { &mut *(s as *mut String as *mut RustString) } in from_mut()
28 unsafe { mem::transmute::<RustString, String>(self) } in into_string()
32 unsafe { &*(self as *const RustString as *const String) } in as_string() constant
36 unsafe { &mut *(self as *mut RustString as *mut String) } in as_mut_string()
40 impl Drop for RustString { implementation
46 const_assert_eq!(mem::size_of::<[usize; 3]>(), mem::size_of::<RustString>());
[all …]
Drust_vec.rs4 use crate::rust_string::RustString;
77 impl RustVec<RustString> {
80 let ptr = v.as_mut_ptr().cast::<RustString>(); in from_vec_string()
87 Self::from_ref(unsafe { &*(v as *const Vec<String> as *const Vec<RustString>) }) in from_ref_vec_string()
91 Self::from_mut(unsafe { &mut *(v as *mut Vec<String> as *mut Vec<RustString>) }) in from_mut_vec_string()
103 unsafe { &*(self as *const RustVec<RustString> as *const Vec<String>) } in as_vec_string()
107 unsafe { &mut *(self as *mut RustVec<RustString> as *mut Vec<String>) } in as_mut_vec_string()
Dlib.rs504 pub use crate::rust_string::RustString;
/external/rust/cxx/syntax/
Datom.rs22 RustString, enumerator
48 "String" => Some(RustString), in from_str()
79 RustString => "String", in as_ref()
Dimproper.rs18 Definite(atom == RustString) in determine_improper_ctype()
Dpod.rs13 CxxString | RustString => false, in is_guaranteed_pod()
Dcheck.rs128 | Some(F32) | Some(F64) | Some(RustString) => return, in check_type_rust_vec()
168 Some(Char) | Some(RustString) => {} in check_type_shared_ptr()
189 Some(Char) | Some(RustString) => {} in check_type_weak_ptr()
214 Some(Bool) | Some(RustString) => {} in check_type_cxx_vector()
Dtokens.rs20 } else if ident.rust == RustString { in to_tokens()
/external/rust/cxx/macro/src/
Dexpand.rs452 if arg.ty == RustString { in expand_cxx_function_decl()
520 Type::Ident(ident) if ident.rust == RustString => { in expand_cxx_function_shim()
521 quote_spanned!(span=> #var.as_mut_ptr() as *const ::cxx::private::RustString) in expand_cxx_function_shim()
539 Type::Ident(ident) if ident.rust == RustString => match ty.mutable { in expand_cxx_function_shim()
540 false => quote_spanned!(span=> ::cxx::private::RustString::from_ref(#var)), in expand_cxx_function_shim()
541 true => quote_spanned!(span=> ::cxx::private::RustString::from_mut(#var)), in expand_cxx_function_shim()
543 Type::RustVec(vec) if vec.inner == RustString => match ty.mutable { in expand_cxx_function_shim()
641 Type::Ident(ident) if ident.rust == RustString => { in expand_cxx_function_shim()
652 if vec.inner == RustString { in expand_cxx_function_shim()
666 Type::Ident(ident) if ident.rust == RustString => match ty.mutable { in expand_cxx_function_shim()
[all …]
/external/rust/cxx/src/symbols/
Drust_vec.rs4 use crate::rust_string::RustString;
90 rust_vec_shims!("string", RustString);
/external/rust/cxx/gen/src/
Dwrite.rs213 Some(RustString) => out.builtin.rust_string = true, in pick_includes_and_builtins()
731 if arg.ty == RustString { in write_cxx_function_shim()
829 } else if arg.ty == RustString { in write_cxx_function_shim()
1026 if arg.ty != RustString && out.types.needs_indirect_abi(&arg.ty) { in write_rust_function_shim_impl()
1097 ty if ty != RustString && out.types.needs_indirect_abi(ty) => write!(out, "$.value"), in write_rust_function_shim_impl()
1325 RustString => write!(out, "::rust::String"), in write_atom()