ctypes unit
Common C type definitions.
The ctypes unit contains the definitions of commonly found C types.
It can be used when interfaces to C libraries need to be defined. The types
here are correct on all platforms, 32 or 64 bit.
The main advantage of using this file is to make sure that all C header import units use the same definitions for basic C types.
The h2pas program can include the ctypes unit
automatically in the units it generates. The -C command-line
switch can be used for this.
Types
cbool | type | C boolean (longbool). |
cchar | type | C character type (No signedness specification, 8 bit integer). |
cdouble | type | Double precision floating point type (double). |
cfloat | type | Single precision floating point type (single). |
cint | type | C integer (commonly 32 bit). |
cint16 | type | 16-bit signed integer. |
cint32 | type | 32-bit signed integer (commonly: int). |
cint64 | type | 64-bit integer. |
cint8 | type | 8-bit signed integer. |
clong | type | long integer (32/64 bit, depending on CPU register size). |
clongdouble | type | Long precision floating point type (extended/double, depending on CPU). |
clonglong | type | Long (64-bit) integer. |
coff_t | type | Generic type to indicate offset. |
cschar | type | C signed character type (8 bit signed integer). |
cshort | type | Short integer (16 bit). |
csigned | type | Signed integer (commonly 32 bit). |
csint | type | Signed integer (commonly 32 bit). |
csize_t | type | Generic type to contain a size of all kinds of structures. |
cslong | type | Signed long integer (32/64 bit, depending on CPU register size). |
cslonglong | type | Signed long (64-bit) integer. |
csshort | type | Short signed integer (16 bit). |
cuchar | type | C unsigned character type (8 bit unsigned integer). |
cuint | type | Unsigned integer (commonly 32 bit). |
cuint16 | type | 16-bit unsigned integer. |
cuint32 | type | 32-bit unsigned integer. |
cuint64 | type | Unsigned 64-bit integer. |
cuint8 | type | 8-bit unsigned integer. |
culong | type | Unsigned long integer (32/64 bit, depending on CPU register size). |
culonglong | type | Unsigned long (64-bit) integer. |
cunsigned | type | Unsigned integer (commonly 32 bit). |
cushort | type | Short unsigned integer (16 bit). |
pcbool | type | Pointer to cbool type. |
pcchar | type | Pointer to cchar type. |
pcdouble | type | Pointer to cdouble type. |
pcfloat | type | Pointer to cfloat type. |
pcint | type | Pointer to cint type. |
pcint16 | type | Pointer to cint16 type. |
pcint32 | type | Pointer to cint32 type. |
pcint64 | type | Pointer to cint64 type. |
pcint8 | type | Pointer to cint8 type. |
pclong | type | Pointer to clong type. |
Pclongdouble | type | Pointer to clongdouble type. |
pclonglong | type | Pointer to clonglong type. |
pcschar | type | Pointer to cschar type. |
pcshort | type | Pointer to cshort type. |
pcsigned | type | Pointer to csigned type. |
pcsint | type | Pointer to csint type. |
pcsize_t | type | Pointer to generic size type. |
pcslong | type | Pointer to cslong type. |
pcslonglong | type | Pointer to cslonglong type. |
pcsshort | type | Pointer to csshort type. |
pcuchar | type | Pointer to cuchar type. |
pcuint | type | Pointer to cuint type. |
pcuint16 | type | Pointer to cuint16 type. |
pcuint32 | type | Pointer to cuint32 type. |
pcuint64 | type | Pointer to cuint64 type. |
pcuint8 | type | Pointer to cuint8 type. |
pculong | type | Pointer to culong type. |
pculonglong | type | Pointer to culonglong type. |
pcunsigned | type | Pointer to cunsigned type. |
pcushort | type | Pointer to cushort type. |
Uses
An experiment, built from development snapshots. Not the official Free Pascal or Lazarus documentation.
