[Delphi] Delphi版本号对照

2017-05-29 19:57:52来源:CSDN作者:Hmillet人点击



VER300    Delphi Seattle / C++Builder Seattle    23    230
    (Delphi:Win32/Win64/OSX/iOS32/iOS64/Android) (C++Builder:Win32/Win64/OSX/iOS32/iOS64/Android)        
VER290    Delphi XE8 / C++Builder XE8    22    220
    (Delphi:Win32/Win64/OSX/iOS32/iOS64/Android) (C++Builder:Win32/Win64/OSX/iOS32/iOS64/Android)        
VER280    Delphi XE7 / C++Builder XE7    21    210
    (Delphi:Win32/Win64/OSX/iOS/Android) (C++Builder:Win32/Win64/OSX/iOS/Android)        
VER270    Delphi XE6 / C++Builder XE6    20    200
    (Delphi:Win32/Win64/OSX/iOS/Android) (C++Builder:Win32/Win64/OSX/iOS/Android)        
VER260    Delphi XE5 / C++Builder XE5    19    190
    (Delphi:Win32/Win64/OSX/iOS/Android) (C++Builder:Win32/Win64/OSX/iOS)        
VER250    Delphi XE4 / C++Builder XE4    18    180
    (Delphi:Win32/Win64/OSX/iOS) (C++Builder:Win32/Win64/OSX)        
VER240    Delphi XE3 / C++Builder XE3    17    170
    (Delphi:Win32/Win64/OSX) (C++Builder:Win32/Win64/OSX)        
VER230    Delphi XE2 / C++Builder XE2    16    160
    (Delphi:Win32/Win64/OSX) (C++Builder:Win32/OSX)        
            161 is the version for the five FireMonkey packages at XE2 Update 2:
            fmi161.bpl, fmx161.bpl, fmxase161.bpl, fmxdae161.bpl, and fmxobj161.bpl.
VER220    Delphi XE / C++Builder XE (Win32)    15    150
VER210    Delphi 2010 / C++Builder 2010 (Win32)    14    140
VER200    Delphi 2009 / C++Builder 2009 (Win32)    12    120
VER190    Delphi 2007 for .Net *    11    110
VER180 or VER185    Delphi 2007 / C++Builder 2007 for Win32 *    11    110
VER180    Delphi 2006 / C++Builder 2006 (Win32/.Net) and Delphi/C++Builder 2007 for Win32    10    100
VER170    Delphi 2005 (Win32/.Net)    9    90
VER160    Delphi 8 for .Net    8    80
VER150    Delphi 7 (and 7.1)    7    70
VER140    Delphi 6 / C++Builder 6    6    60
VER130    Delphi 5 / C++Builder 5    5    NA
VER125    C++Builder 4    4    NA
VER120    Delphi 4    4    NA
VER110    C++Builder 3    3    NA
VER100    Delphi 3    3    NA
VER93    C++Builder 1    NA    NA
VER90    Delphi 2    2    NA
VER80    Delphi 1    1    NA
VER70    Borland Pascal 7.0    NA    NA
VER15    Turbo Pascal for Windows 1.5    NA    NA
VER10    Turbo Pascal for Windows 1.0    NA    NA
VER60    Turbo Pascal 6.0    NA    NA
VER55    Turbo Pascal 5.5    NA    NA
VER50    Turbo Pascal 5.0    NA    NA
VER40    Turbo Pascal 4.0    NA    NA
VER30  : Turbo Pascal 3
VER20  : Turbo Pascal 2
VER10  :Turbo Pascal 1

编译时可以判断版本号:

 

{$IF CompilerVersion >= 18.5}//some code only compiled for Delphi 2007 and later{$IFEND}


Delphi 10.1 Berlin  - 31

Delphi XE3  - 24
Delphi XE2  - 23

Delphi XE   - 22
Delphi 2010 - 21
Delphi 2009 - 20
Delphi 2007 - 18.5
Delphi 2006 - 18
Delphi 2005 - 17
Delphi 8    - 16
Delphi 7    - 15
Delphi 6    - 14

判断当前 Delphi 的运行库版本:

procedure TForm1.FormCreate(Sender: TObject);begin  Edit1.Text := FloatToStr(System.CompilerVersion);end;

 

Compiler Directives

Delphi Compiler DirectiveAssociated Symbol
Align fields (Delphi){A},{A},{ALIGN}
Application type (Delphi){$APPTYPE}
Assert directives (Delphi){C},{C},{ASSERTIONS}
Boolean short-circuit evaluation (Delphi compiler directive){B},{B},{BOOLEVAL}
Code align (Delphi){$CODEALIGN}
Conditional compilation (Delphi){IFDEF}, {IFDEF}, {IFNDEF}, {IF}, {IF}, {ELSEIF}, {ELSE}, {ELSE}, {ENDIF}, {$IFEND}
Debug information (Delphi){D},{D},{DEBUGINFO}
DEFINE directive (Delphi){$DEFINE}
DENYPACKAGEUNIT directive (Delphi){$DENYPACKAGEUNIT}
Description (Delphi){D},{D},{DESCRIPTION}
DESIGNONLY directive (Delphi){$DESIGNONLY}
ELSE (Delphi){$ELSE}
ELSEIF (Delphi){$ELSEIF}
ENDIF directive (Delphi){$ENDIF}
Executable extension (Delphi){E},{E},{EXTENSION}
Export symbols (Delphi){$ObjExportAll}
Extended syntax (Delphi){X},{X},{EXTENDEDSYNTAX}
Extended type compatibility (Delphi){$EXTENDEDCOMPATIBILITY}
External Symbols (Delphi){$EXTERNALSYM [ 'typeNameInHpp' [ 'typeNameInHppUnion' ]]}
Floating point precision control (Delphi for x64){$EXCESSPRECISION}
HIGHCHARUNICODE directive (Delphi){$HIGHCHARUNICODE}
Hints (Delphi){$HINTS}
HPP emit (Delphi){$HPPEMIT}
IFDEF directive (Delphi){$IFDEF}
IF directive (Delphi){$IF}
IFEND directive (Delphi){$IFEND}
IFNDEF directive (Delphi){$IFNDEF}
IFOPT directive (Delphi){$IFOPT}
Image base address{$IMAGEBASE}
Implicit Build (Delphi){$IMPLICITBUILD}
Imported data{G},{G},{IMPORTEDDATA}
Include file (Delphi){I},{I},{INCLUDE}
Input output checking (Delphi){I},{I},{IOCHECKS}
Compiler directives for libraries or shared objects (Delphi){LIBPREFIX}, {LIBPREFIX}, {LIBSUFFIX}, {$LIBVERSION}
Legacy IFEND (Delphi){$LEGACYIFEND}
Link object file (Delphi){L file},{L file},{LINK file}
Local symbol information (Delphi){L+},{L+},{LOCALSYMBOLS}
Long strings (Delphi){H},{H},{LONGSTRINGS}
Memory allocation sizes (Delphi){M},{M},{MINSTACKSIZE},{$MAXSTACKSIZE}
MESSAGE directive (Delphi){$MESSAGE }
METHODINFO directive (Delphi){$METHODINFO}
Minimum enumeration size (Delphi){Z1},{Z1},{Z2},{Z4},{Z4},{MINENUMSIZE 1},{MINENUMSIZE 2},{MINENUMSIZE 2},{MINENUMSIZE 4}
NODEFINE directive (Delphi){$NODEFINE [ 'typeNameInHpp' [ 'typeNameInHppUnion' ]]}
NOINCLUDE (Delphi){$NOINCLUDE}
OBJTYPENAME directive (Delphi){$OBJTYPENAME typeIdent ['{B|N}typeNameInObj']}
Old type layout (Delphi){$OLDTYPELAYOUT ON}
Open String Parameters (Delphi){P},{P},{OPENSTRINGS}
Optimization (Delphi){O},{O},{OPTIMIZATION}
Overflow checking (Delphi){Q},{Q},{OVERFLOWCHECKS}
PE (portable executable) header flags (Delphi){SetPEFlags},{SetPEFlags},{SetPEOptFlags}
PE header operating system version{$SETPEOSVERSION}
PE header subsystem version{$SETPESUBSYSVERSION}
PE header user version{$SETPEUSERVERSION}
Pentium-safe FDIV operations (Delphi){U},{U},{SAFEDIVIDE}
Pointer Math (Delphi){$POINTERMATH}
Range checking{R},{R},{RANGECHECKS}
Real48 compatibility (Delphi){$REALCOMPATIBILITY}
Regions{REGION},{REGION},{ENDREGION}
Reserved address space for resources (Delphi, Linux){M},{M},{RESOURCERESERVE}
Resource file (Delphi){R},{R},{RESOURCE}
RTTI directive (Delphi){$RTTI INHERIT|EXPLICIT}
RUNONLY directive (Delphi){$RUNONLY}
Run-Time Type Information (Delphi){M},{M},{TYPEINFO}
Scoped Enums (Delphi){$SCOPEDENUMS}
Stack frames (Delphi){W},{W},{STACKFRAMES}
Strong link types (Delphi){$STRONGLINKTYPES}
Symbol declaration and cross-reference information (Delphi){Y},{Y},{REFERENCEINFO},{DEFINITIONINFO}
Type-checked pointers (Delphi){T},{T},{TYPEDADDRESS}
UNDEF directive (Delphi){$UNDEF}
Var-string checking (Delphi){V},{V},{VARSTRINGCHECKS}
Warning messages (Delphi){$WARN}
Warnings (Delphi){$WARNINGS}
Weak packaging{$WEAKPACKAGEUNIT}
WEAKLINKRTTI directive (Delphi){$WEAKLINKRTTI}
Writeable typed constants (Delphi){J},{J},{WRITEABLECONST}
Zero-based strings (Delphi){$ZEROBASEDSTRINGS}

Predefined Conditionals

 

CategorySymbolDCC32DCC64DCCOSXDCCIOSARMDCCIOS32DCCAARMDCCIOSARM64Comments
  Since XE2    Since XE2    Since XE3    Since XE3  In XE5Since XE8
CompilerDCCDEFINEDDEFINEDDEFINEDDEFINEDDEFINEDDEFINEDDEFINED 
VER310DEFINEDDEFINEDDEFINEDDEFINEDDEFINEDDEFINEDDEFINEDFor Delphi XE8, compiler version 29.0 hasVER310 defined.
 
For a list of compiler
versions, see Compiler
Versions.
PlatformCONSOLEDEFINEDDEFINEDDEFINEDDEFINEDDEFINEDDEFINEDDEFINEDDefined if an application is being compiled as a console application.
IOSnot definednot definednot definedDEFINEDDEFINEDN/ADEFINEDDefined if the target platform is iOS.
*New* in XE4/iOS
NATIVECODEDEFINEDDEFINEDDEFINEDDEFINEDDEFINEDDEFINEDDEFINEDSince Delphi.Net
MSWINDOWSDEFINEDDEFINEDnot definednot definednot definednot definednot definedIndicates that the operating environment is Windows. Use MSWINDOWS
to test for any flavor of the Windows platform instead of WIN32.
WIN32DEFINEDnot definednot definednot definednot definednot definednot definedTarget platform is the native 32-bit Windows platform.
WIN64not definedDEFINEDnot definednot definednot definednot definednot definedTarget platform is 64-bit Windows.
*New* in XE2/x64
MACOSnot definednot definedDEFINEDDEFINEDDEFINEDnot definednot definedTarget platform is Mac OS X.
*New* in XE2/OSX
MACOS32not definednot definedDEFINEDDEFINEDDEFINEDnot definednot definedTarget platform is 32-bit Mac OS X.
*New* in XE2/OSX
LINUXnot definednot definednot definednot definednot definednot definednot definedSince Kylix
LINUX32not definednot definednot definednot definednot definednot definednot definedSince Kylix
POSIXnot definednot definedDEFINEDDEFINEDDEFINEDDEFINEDDEFINEDSince Kylix
POSIX32not definednot definedDEFINEDDEFINEDDEFINEDDEFINEDDEFINEDSince Kylix
ANDROIDnot definednot definednot definednot definednot definedDEFINEDnot definedDefined if the target platform is Android.
*New in XE5
CPUCPUARMnot definednot definednot definedDEFINEDnot definedDEFINEDDEFINEDDefined if the CPU is based on the ARM architecture, such as the Delphi
mobile compiler for the iOS device (DCCIOSARM.EXE).
*New* in XE4/iOS
CPU386DEFINEDnot definedDEFINEDnot definedDEFINEDnot definednot definedIndicates that the CPU is an Intel 386 or later.
CPUX86DEFINEDnot definedDEFINEDnot definedDEFINEDnot definednot definedCPU is an Intel 386 or later on any platform.
*New* in XE2/x64
CPUX64not definedDEFINEDnot definednot definednot definednot definednot definedThe CPU supports the x86-64 instruction set, and is in a 64-bit environment.
*New* in XE2/x64
CPU32BITSDEFINEDnot definedDEFINEDDEFINEDDEFINEDDEFINEDnot definedThe CPU is in a 32-bit environment, such as DCC32.EXE.
*New* in XE8
CPU64BITSnot definedDEFINEDnot definednot definednot definednot definedDEFINEDThe CPU is in a 64-bit environment, such as DCC64.EXE.
*New* in XE8
CPUARM32not definednot definednot definedDEFINEDnot definedDEFINEDnot definedThe CPU is in a 32-bit ARM environment, such as DCCIOSARM.EXE.
*New* in XE8
CPUARM64not definednot definednot definednot definednot definednot definedDEFINEDThe CPU is in a 64-bit ARM environment, such as DCCIOSARM64.EXE.
*New* in XE8
Availability         
ALIGN_STACKnot definednot definedDEFINEDnot definedDEFINEDnot definednot definedDefined in code that may be shared with the OS X compiler and another compiler
on another platform such as Linux that does not have a rigid stack alignment
requirement. For more information, see Eli Boling's blog at
http://blogs.embarcadero.com/eboling/2009/05/20/5607 .
*New* in XE2/OSX
ASSEMBLERDEFINEDDEFINEDDEFINEDnot definedDEFINEDnot definednot definedAssembler syntax is accepted.
AUTOREFCOUNTnot definednot definednot definedDEFINEDDEFINEDDEFINEDDEFINEDDefined for compilers that use automatic reference counting, such as the Delphi
mobile compilers.
*New* in XE4/iOS
EXTERNALLINKERnot definednot definednot definedDEFINEDnot definedDEFINEDDEFINEDDefined for compilers that have an external linker and the LLVM code generator; the
Delphi mobile compilers have the external ld linker and use LLVM as code generator.
*New* in XE4/iOS
UNICODEDEFINEDDEFINEDDEFINEDDEFINEDDEFINEDDEFINEDDEFINEDUNICODE is defined as the default string type.
CONDITIONALEXPRESSIONSDEFINEDDEFINEDDEFINEDDEFINEDDEFINEDDEFINEDDEFINEDTests for the use of the $IF directive.
ELFnot definednot definednot definednot definednot definednot definednot definedDefined when targeting Executable and Linkable Format (ELF) files.
NEXTGENnot definednot definednot definedDEFINEDDEFINEDDEFINEDDEFINEDDefined for compilers (such as the Delphi mobile compilers) that use
"next-generation" language features, such as 0-based strings.
*New* in XE4/iOS
PC_MAPPED_EXCEPTIONSnot definednot definedDEFINEDnot definedDEFINEDnot definednot definedDefined when compiling on a platform or for a target platform that uses address
maps instead of stack frames to unwind exceptions (such as OS X).
*New* in XE2.
PICneverneverDEFINED if -P is specifiedneverDEFINED if
-P is specified
always definedneverDefined for platforms that require Position-Independent Code (PIC), such as OS X.
UNDERSCOREIMPORTNAMEDEFINEDnot definedDEFINEDnot definedDEFINEDnot definednot definedDefined for compilers that add a leading underscore (for example, in names of
dynamic libraries imported from Mac OS).
*New* in XE4/iOS
WEAKREFnot definednot definednot definedDEFINEDDEFINEDDEFINEDDEFINEDDefined for compilers that can use weak references (the[weak] attribute).
*New* in XE4/iOS
WEAKINSTREFnot definednot definednot definedDEFINEDDEFINEDDEFINEDDEFINEDDefined when weak references are defined for instances.
*New* in XE4/iOS
WEAKINTFREFnot definednot definednot definedDEFINEDDEFINEDDEFINEDDEFINEDDefined when weak references are defined for interfaces.
*New* in XE4/iOS
         

In the table column heads:

  • DCC32 is the 32-bit Windows Delphi compiler.
  • DCC64 is the 64-bit Windows Delphi compiler.
  • DCCOSX is the Mac OS X Delphi compiler.
  • DCCIOSARM is the Delphi compiler for 32-bit iOS Devices.
  • DCCIOS32 is the Delphi compiler for iOS Simulators.
  • DCCAARM.EXE is the Delphi compiler for Android devices.
  • DCCIOSARM64 is the Delphi compiler for 64-bit iOS devices.

 

?
12345678{$IFDEF CONDITIONALEXPRESSIONS}   {$IF CompilerVersion >= 17.0}     {$DEFINE HAS_INLINE}   {$IFEND}   {$IF RTLVersion >= 14.0}     {$DEFINE HAS_ERROUTPUT}   {$IFEND}{$ENDIF}

最新文章

123

最新摄影

闪念基因

微信扫一扫

第七城市微信公众平台