[][src]Struct c2rust_transpile::convert_type::TypeConverter

pub struct TypeConverter {
    pub translate_valist: bool,
    // some fields omitted
}

Fields

translate_valist: bool

Methods

impl TypeConverter[src]

pub fn new(emit_no_std: bool) -> TypeConverter[src]

pub fn features_used(&self) -> &HashSet<&'static str>[src]

pub fn declare_decl_name(&mut self, decl_id: CDeclId, name: &str) -> String[src]

pub fn alias_decl_name(&mut self, new_decl_id: CDeclId, old_decl_id: CDeclId)[src]

pub fn resolve_decl_name(&self, decl_id: CDeclId) -> Option<String>[src]

pub fn declare_field_name(
    &mut self,
    record_id: CRecordId,
    field_id: CFieldId,
    name: &str
) -> String
[src]

pub fn resolve_field_name(
    &self,
    record_id: Option<CRecordId>,
    field_id: CFieldId
) -> Option<String>
[src]

Resolve the Rust name associated with a field declaration. The optional record_id is used as a hint to speed up the process of finding the field's name.

pub fn convert_pointer(
    &mut self,
    ctxt: &TypedAstContext,
    qtype: CQualTypeId
) -> Result<P<Ty>, TranslationError>
[src]

pub fn is_inner_type_valist(ctxt: &TypedAstContext, qtype: CQualTypeId) -> bool[src]

pub fn convert(
    &mut self,
    ctxt: &TypedAstContext,
    ctype: CTypeId
) -> Result<P<Ty>, TranslationError>
[src]

Convert a C type to a Rust one. For the moment, these are expected to have compatible memory layouts.

Auto Trait Implementations

Blanket Implementations

impl<T> From for T[src]

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> BorrowMut for T where
    T: ?Sized
[src]

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<E> SpecializationError for E[src]

impl<T> Erased for T[src]

impl<T> Send for T where
    T: ?Sized
[src]

impl<T> Sync for T where
    T: ?Sized
[src]

impl<T> Make for T[src]

impl<T> MaybeResult for T[src]

impl<'a, T> Captures for T where
    T: ?Sized
[src]

impl<T> Erased for T