C Type Handles

(PHP 7 >= 7.4.0, PHP 8)



final class FFI\CType {
/* メソッド */
public getAlignment(): int
public getArrayLength(): int
public getAttributes(): int
public getEnumKind(): int
public getFuncABI(): int
public getFuncParameterCount(): int
public getFuncParameterType(int $index): FFI\CType
public getKind(): int
public getName(): string
public getSize(): int
public getStructFieldNames(): array
public getStructFieldOffset(string $name): int
public getStructFieldType(string $name): FFI\CType


add a note add a note

User Contributed Notes 1 note

scorninpc at php dot net
3 years ago
You can compare CTypes if you want to know if the type are correct

\FFI::typeof(\FFI::addr($a)) == \FFI::typeof(\FFI::new("void *"))

CType need some methods, like equal() or toString(), but .....
To Top