c pas 数据类型对照表
https://docwiki.embarcadero.com/RADStudio/Sydney/en/Declared_Constants
https://docwiki.embarcadero.com/RADStudio/Sydney/en/Simple_Types_(Delphi)
https://docwiki.embarcadero.com/RADStudio/Sydney/en/64-bit_Windows_Data_Types_Compared_to_32-bit_Windows_Data_Types
https://docwiki.embarcadero.com/RADStudio/Sydney/en/The_Fundamental_Types
https://docwiki.embarcadero.com/RADStudio/Sydney/en/Delphi_Intrinsic_Routines 个平台下系统函数完成度 表
https://docwiki.embarcadero.com/RADStudio/Sydney/en/Floating-Point_Rounding_Routines 浮点取整 表
https://docwiki.embarcadero.com/RADStudio/Sydney/en/Floating-Point_Number_Control_Routines 浮点fpu有关
https://docwiki.embarcadero.com/RADStudio/Sydney/en/Delphi_to_C%2B%2B_types_mapping 官方delphi to c数据类型表
https://wiki.freepascal.org/Pascal_for_C_users 官方freepascal to c数据类型表
https://wiki.freepascal.org/C_to_Pascal c to pas 工具大全 表
https://wiki.freepascal.org/Creating_bindings_for_C_libraries 内含bit结构体转换示例
http://rvelthuis.de/articles/articles-convert.html 内含bit结构体转换示例
中文解释
-
delphi gcc
-
ShortInt char 1 signed char -128~127
-
Byte unsigned char 1 none 0~255
-
Integer int 4 signed int -2147483648~2147483647
-
Cardinal LongWord unsigned int 4 unsigned 0~4294967295
-
SmallInt short 2 short int -32768~32767
-
Word unsigned short 2 unsigned short int 0~65535
-
long 4 long int 2147483648~2147483647
-
unsigned long 4 unsignedlong 0~4294967295
-
Single float 4 none 3.4E +/-38(7 DIGITS)
-
Double double 8 none 1.7E +/- 308(15 digits)
-
Extended long double 10 none 1.2E +/- 4932(19 digits)
-
32 64
-
Int64 UInt64 8 bytes
-
NativeInt NativeUInt 4 bytes 8 bytes