alien.c-types vocabulary - Factor Documentation (original) (raw)

alien.c-types vocabulary
Factor handbook » Vocabulary index

Documentation
C type specifiers

Metadata

Parents: alien
Authors: Slava Pestov

Words

Tuple classes

Class Superclass Slots
abstract-c-type tuple class boxed-class boxer-quot unboxer-quot getter setter size signed align align-first
c-type abstract-c-type boxer unboxer rep
long-long-type c-type
no-c-type tuple word
pointer tuple to

Singleton classes

void

Predicate classes

Class Superclass
c-type-word word
typedef-word c-type-word

Mixin classes

value-type

Union classes

c-type-name

Generic words

Word Stack effect
base-type ( c-type -- c-type )
c-type-align ( name -- n )
c-type-align-first ( name -- n )
c-type-boxed-class ( name -- class )
c-type-boxer-quot ( name -- quot )
c-type-class ( name -- class )
c-type-copier ( name -- quot )
c-type-getter ( name -- quot )
c-type-rep ( name -- rep )
c-type-setter ( name -- quot )
c-type-signed ( name -- boolean )
c-type-string ( c-type -- string )
c-type-unboxer-quot ( name -- quot )
heap-size ( name -- size )
lookup-c-type ( name -- c-type )
pointer-string ( pointer -- string/f )

Macro words

Word Stack effect
alien-copy-value ( c-type -- quot: ( c-ptr offset -- value ) )
alien-value ( c-type -- quot: ( c-ptr offset -- value ) )
set-alien-value ( c-type -- quot: ( value c-ptr offset -- ) )

Symbol words

bool
c-string
c-type-protocol
char
double
f32
f64
float
int
int16_t
int32_t
int64_t
int8_t
intptr_t
isize
long
longlong
ptrdiff_t
s16
s32
s64
s8
short
size_t
ssize_t
u16
u32
u64
u8
uchar
uint
uint16_t
uint32_t
uint64_t
uint8_t
uintptr_t
ulong
ulonglong
ushort
usize
void*

Ordinary words

Word Stack effect
(signed-interval) ( bytes -- from to )
(unsigned-interval) ( bytes -- from to )
( -- c-type )
( -- c-type )
( to -- pointer )
>c-bool ( ? -- int )
alien-element ( n c-ptr c-type -- value )
array-accessor ( n c-ptr c-type -- c-ptr offset c-type )
c-bool> ( int -- ? )
c-type-clamp ( value c-type -- value' )
c-type-interval ( c-type -- from to )
if-void ( ..a c-type true: ( ..a -- ..b ) false: ( ..a c-type -- ..b ) -- ..b )
no-c-type ( word -- * )
primitive-types ( -- value )
resolve-typedef ( name -- c-type )
set-alien-element ( value n c-ptr c-type -- )
signed-interval ( c-type -- from to )
typedef ( old new -- )
unsigned-interval ( c-type -- from to )

Class predicate words

Word Stack effect
abstract-c-type? ( object -- ? )
c-type-name? ( object -- ? )
c-type-word? ( object -- ? )
c-type? ( object -- ? )
long-long-type? ( object -- ? )
no-c-type? ( object -- ? )
pointer? ( object -- ? )
typedef-word? ( object -- ? )
value-type? ( object -- ? )
void? ( object -- ? )

Files

resource:basis/alien/c-types/c-types.factor
resource:basis/alien/c-types/c-types-docs.factor
resource:basis/alien/c-types/c-types-tests.factor

Metadata files

resource:basis/alien/c-types/authors.txt
resource:basis/alien/c-types/summary.txt