Enum witx::BuiltinType [−][src]
pub enum BuiltinType {
Char,
U8 {
lang_c_char: bool,
},
U16,
U32 {
lang_ptr_size: bool,
},
U64,
S8,
S16,
S32,
S64,
F32,
F64,
}
Variants
This is a 32-bit unicode scalar value, not a code point.
Same as the Rust language’s char
type.
An 8-bit unsigned integer.
Fields of U8
lang_c_char: bool
Indicates whether this type is intended to represent the char
type in the C language. The C char
type is often unsigned, but
it’s language-specific. At an interface-types level this is an
unsigned byte but binding generators may wish to bind this as the
language-specific representation for a C character instead.
This is also currently used exclusively in conjunction with @witx pointer
to hint that it’s pointing to unicode string data as well.
A 16-bit unsigned integer.
A 32-bit unsigned integer.
Fields of U32
lang_ptr_size: bool
Indicates that this 32-bit value should actually be considered a
pointer-like value in language bindings. At the interface types
layer this is always a 32-bit unsigned value, but binding
generators may wish to instead bind this as the equivalent of C’s
size_t
for convenience with other APIs.
This allows witx authors to communicate the intent that the argument or return-value is pointer-like.
A 64-bit unsigned integer.
An 8-bit signed integer
A 16-bit signed integer
A 32-bit signed integer
A 64-bit signed integer
A 32-bit floating point value.
A 64-bit floating point value.
Implementations
Trait Implementations
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
This method tests for !=
.
Returns a human-readable name of this token to display when generating errors about this token missing. Read more
Auto Trait Implementations
impl RefUnwindSafe for BuiltinType
impl Send for BuiltinType
impl Sync for BuiltinType
impl Unpin for BuiltinType
impl UnwindSafe for BuiltinType
Blanket Implementations
Mutably borrows from an owned value. Read more