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.

8-bit signed integer Pointer to cint8 type. 8-bit unsigned integer Pointer to cuint8 type. C character type (No signedness specification, 8 bit integer) Pointer to cchar type. C signed character type (8 bit signed integer) Pointer to cschar type. C unsigned character type (8 bit unsigned integer). Pointer to cuchar type. 16-bit signed integer. Pointer to cint16 type. 16-bit unsigned integer. Pointer to cuint16 type. Short integer (16 bit) Pointer to cshort type. Short signed integer (16 bit) Pointer to csshort type. Short unsigned integer (16 bit) Pointer to cushort type. 32-bit signed integer (commonly: int) Pointer to cint32 type. 32-bit unsigned integer Pointer to cuint32 type. C integer (commonly 32 bit) Pointer to cint type. Signed integer (commonly 32 bit) Pointer to csint type. Unsigned integer (commonly 32 bit) Pointer to cuint type. Signed integer (commonly 32 bit) Pointer to csigned type. Unsigned integer (commonly 32 bit) Pointer to cunsigned type. 64-bit integer Pointer to cint64 type. Unsigned 64-bit integer Pointer to cuint64 type. Long (64-bit) integer Pointer to clonglong type. Signed long (64-bit) integer Pointer to cslonglong type. Unsigned long (64-bit) integer Pointer to culonglong type. C boolean (longbool) Pointer to cbool type. long integer (32/64 bit, depending on CPU register size) Pointer to clong type. Signed long integer (32/64 bit, depending on CPU register size) Pointer to cslong type. Unsigned long integer (32/64 bit, depending on CPU register size) Pointer to culong type. Single precision floating point type (single) Pointer to cfloat type. Double precision floating point type (double) Pointer to cdouble type. Long precision floating point type (extended/double, depending on CPU) Pointer to clongdouble type. Override assignment operator for clongdouble type. Override assignment operator for clongdouble type. Generic type to contain a size of all kinds of structures Pointer to generic size type Generic type to indicate offset Implement assignment of a clongdouble to a double type. This operator allows to assign a clongdouble to a Double type. Implement assignment of a double to a clongdouble type. This operator allows to assign a double to a clongdouble type. Implement addition of clongdouble and double. This operator allows to add double and clongdouble typed values. The result is a double typed value. This operator allows to add clongdouble and double typed values. The result is a double typed value. Implement subtraction of clongdouble and double. This operator allows to subtract a clongdouble typed value from a double typed value. The result is a double typed value. Implement subtraction of double and clongdouble. This operator allows to subtract a double typed value from a clongdouble typed value. The result is a double typed value. Implement multiplication of double and clongdouble. This operator allows to multiply a clongdouble typed value with a double typed value. The result is a double typed value. Implement multiplication of clongdouble and double. This operator allows to multiply a double typed value with a clongdouble typed value. the result is a double typed value. Implement division of clongdouble and double. This operator allows to divide a double typed value by a clongdouble typed value. the result is a double typed value. Implement division of double and clongdouble. This operator allows to divide a clongdouble typed value by a double typed value. the result is a double typed value. Implement equality of double and clongdouble. This operator compares the values of a clongdouble typed value and a double typed value, and returns True if the values are equal (only double precision is used). Implement equality of clongdouble and double. This operator compares the values of a double typed value and a clongdouble typed value, and returns True if the values are equal (only double precision is used). Implement less than comparison between clongdouble and double. This operator compares the values of a double typed value and a clongdouble typed value, and returns True if the double value is less than the clongdouble value. Implement less than comparison between double and clongdouble. This operator compares the values of a clongdouble typed value and a double typed value, and returns True if the clongdouble value is less than the double value. Implement greater than comparison between clongdouble and double. This operator compares the values of a double typed value and a clongdouble typed value, and returns True if the double value is greater than the clongdouble value. Implement greater than comparison between double and clongdouble. This operator compares the values of a clongdouble typed value and a double typed value, and returns True if the clongdouble value is greater than the double value. Implement greater than or equal comparison between clongdouble and double. This operator compares the values of a double typed value and a clongdouble typed value, and returns True if the double value is greater than or equal to the clongdouble value. Implement greater than or equal comparison between double and clongdouble. This operator compares the values of a clongdouble typed value and a double typed value, and returns True if the clongdouble value is greater than or equal to the double value. Implement less than or equal comparison between clongdouble and double. This operator compares the values of a double typed value and a clongdouble typed value, and returns True if the double value is less than or equal to the clongdouble value. Implement greater than or equal comparison between double and clongdouble. This operator compares the values of a clongdouble typed value and a double typed value, and returns True if the clongdouble value is less than or equal to the double value.