Delphi 언어 기능 및 소개 / 비추천 된 버전 목록
시작하기 전에 Google을 통해 정직하고 진지하게 반복적으로 철저하게 검색하여 해당 항목을 찾을 수 없음을 지적하고 싶습니다.
모든 델파이 (2007에서 최신 릴리스 버전까지), 더 이상 2007 년 이전 버전을 지원하지 않는 "언어 기능", 그리고 소개 된 버전 및 ( 해당되는 경우) 더 이상 사용되지 않거나 개선되거나 제거되었습니다.
필자는 Stack Overflow에서 이와 비슷한 질문을 한 적이 있지만 대부분은 "어떤 기능이 가장 좋습니까?"
누구든지 그러한 목록을 알고 있거나 (또는 컴파일 할 여가 시간이 충분하다면) 매우 감사 할 것입니다.
수락 된 답변에는 그러한 목록에 대한 링크 또는 목록 자체가 포함됩니다.
이 답변에는 새로운 VCL / FMX 기능이
아닌 새로운 언어 기능 만 나열되어 있습니다.
다음은 RAD Studio Docwiki에 대한 링크입니다.
- Rad Studio 10.3 Rio의 새로운 기능
- Delphi 및 C ++ Builder 10.2 Tokyo의 새로운 기능
- Delphi 및 C ++ Builder 10.1 Berlin의 새로운 기능
- Delphi 및 C ++ Builder 10 Seattle의 새로운 기능
- Delphi 및 C ++ Builder XE8의 새로운 기능
- Delphi 및 C ++ Builder XE7의 새로운 기능
- Delphi 및 C ++ Builder XE6의 새로운 기능
- Delphi 및 C ++ Builder XE5의 새로운 기능
- Delphi 및 C ++ Builder XE4의 새로운 기능
- Delphi 및 C ++ Builder XE3의 새로운 기능
- Delphi 및 C ++ Builder XE2의 새로운 기능
- Delphi 및 C ++ Builder XE의 새로운 기능
- Delphi 및 C ++ Builder 2010의 새로운 기능
- Delphi 및 C ++ Builder 2009의 새로운 기능
- RAD Studio의 새로운 기능 (Delphi for Win32 2007)
- RAD Studio의 새로운 기능 (C ++ Builder 2007)
- Delphi 2006의 새로운 기능
- Delphi 2005의 새로운 기능
- Delphi 7의 새로운 기능
- Delphi 6의 새로운 기능
- Delphi 5의 새로운 기능
- Delphi 4의 새로운 기능
- Delphi 3의 새로운 기능
- Delphi 2의 새로운 기능
- 델파이 1 기능
Embarcadero의 전체 목록 : 새로운 기능
참조 : David I 's list
요약:
델파이 10.3.x, 10.4 (아직, 추론입니다)
- 맞춤 관리 형 레코드
- 널 입력 가능 유형
- macOS 64 비트 지원
- Android 64 비트 지원
- 64 비트 Linux 컴파일러는 더 이상 ARC 를 사용하지 않고 대신 Windows 컴파일러에서와 같이 관리되는 기본 수동 관리를 사용합니다. 이를 통해 Windows 또는 OSX에서 Linux로 코드를 포팅하는 것이 훨씬 쉬워집니다.
- 자동 유형 유추가있는 인라인 변수
- Linux에서 활성화시 8 비트 AnsiChar / AnsiString 지원
- C ++ Builder와 Delphi는 이제 모든 호출에 동일한 ABI를 사용합니다.
- Linux 서버 앱 지원 (LLVM 및 ARC를 사용하는 인텔 64 비트).
@
연산자를 사용하여 포인터에 동적 배열을 할당하는 것은 배열을 하드 캐스팅 할 때만 허용됩니다.- 단위 이름의보다 유연한 네임 스페이스 확인
- 모든 플랫폼에서 Utf8String 및 RawByteString 유형에 대한 기본 지원
[weak]
,[unsafe]
및[volatile]
속성은 모든 컴파일러에서 지원됩니다.- OSX에서 확장 된 크기는 이제 16 바이트입니다.
- 수업 및 기록 도우미는 수업의 개인 구성원이나 자신이 확장 한 기록에 액세스 할 수 없습니다 .
- 최대 6.01의 Android를 지원합니다.
- Android 5.1.1 및 iOS 8.4 지원
- 개선 된 OSX 예외 처리
- 64 비트 iOS 지원;
- 새로운 정수 유형 : 모든 플랫폼에서 FixedInt , FixedUInt 32 비트 정수 유형;
- 새로운 플랫폼 종속 정수 유형 : LongInt , LongWord (iOS-64의 64 비트, 다른 모든 플랫폼의 32 비트);
- 동적 배열에서 지원되는 문자열과 유사한 작업
- RTL에 추가 된 병렬 라이브러리
-
function IsManagedType(T: TypeIdentifier): Boolean; function HasWeakRef(T: TypeIdentifier): Boolean; function GetTypeKind(T: TypeIdentifier): TTypeKind; function IsConstValue(Value): boolean;
- 안드로이드 지원; 조건부 정의 ANDROID를 도입
하려면 ArmV6 + Neon 또는 ArmV7이 장착 된 장치가 필요합니다.
- 클래스의 연산자 오버로드 (NextGen 컴파일러 {Android / iOS}에만 해당)
XE4에는 다음과 같은 새로운 조건이 도입 / 활성화되었습니다 :
AUTOREFCOUNT
CPUARM
EXTERNAL_LINKER
IOS
NEXTGEN
UNDERSCOREIMPORTNAME
WEAKREF
WEAKINSTREF
WEAKINTREF- iOS에 대한 지원을 다시 도입했습니다.
- 외부 라이브러리의 종속성을 지정하기위한 새로운
dependency
지시문 (XE8까지 문서화되지 않음) - ARC support in NextGen compilers (including TObject.DisposeOf).
Note that much of the groundwork for ARC was already in XE3, but much of it was disabled - Before the XE4 release,
$IF
statements could only be terminated with$IFEND
, and the$IFDEF
,$IFNDEF
,$IFOPT
directives could only be terminated with$ENDIF
.
At XE4, this changed so that $ENDIF became an accepted terminator for $IF, $IFDEF, $IFNDEF, and $IFOPT.
- Record helpers for built-in types
- Removed support for iOS.
- Atomic intrinsic functions:
AtomicExchange()
,AtomicIncrement()
,AtomicCmpExchange()
,AtomicDecrement()
- Introduction of the [ref] attribute.
- Cross platform support for Mac OSX (32-bit) and iOS;
- Support for Win64;
- Modified RTL to support cross platform;
Packed
Now Forces Byte Alignment of Records (Pre XE2 it did not necessarily do this)Eight new DEFINEs have been added:
ALIGN_STACK
CPUX86
CPUX64
MACOS (Mac operating system)
MACOS32
PC_MAPPED_EXCEPTIONS
PIC
WIN64- Full unit scope names are now required in your
uses
clause. {$ExcessPrecision on/off}
compiler directive (x64 only)- The build-in types differ depending on the target platform (32/64-bit)
- Extended Data Type Is 10 bytes on Win32, but 8 (!) bytes on Win64
- The
{$STRINGCHECKS}
compiler directive is ignored in XE; - New 16-byte value for the
{$ALIGN}
directive: The acceptable values for the{$ALIGN}
directive now include 1, 2, 4, 8, and 16. - new
{$CODEALIGN}
directive, this sets the starting address for a procedure or function. - The
{$STRONGLINKTYPES ON}
directive - Support for regular expressions.
- Enhanced Delphi RTTI (Run Time Type Information).
- Attributes
- The
as
operator can be used to cast an interface reference back to the object from which it was extracted. - The
is
operator can be used to verify whether an interface reference was extracted from a certain class. - Normal unsafe casting can be performed on an interface:
TObject(SomeInterface)
. - new
delayed
directive indicates that an external library such as a DLL is not to be loaded at declaration time but is to wait until the first call to the method - Class Constructor/Destructor
- Intrinsic type
string
now maps toUnicodeString
; {$HighCharUnicode on|off}
compiler directive- Generics;
function Default(T): T
intrinsic function (Undocumented)- Smart pointers;
- Anonymous methods;
- Support for nested exceptions and exception tracing;
- support for pointermath and a new compiler directive:
{$PointerMath on|off}
; - Four new compiler warnings:
W1057 Implicit string cast from '%s' to '%s'
,W1058 Implicit string cast with potential data loss from '%s' to '%s'
,W1059 Explicit string cast from '%s' to '%s'
,W1060 Explicit string cast with potential data loss from '%s' to '%s'
;
- The
Exit
function can take a parameter specifying a result; resourcestrings
as Widestrings;TObject
has a extra hidden pointer toTMonitor
in addition to its VMT pointer;- the
deprecated
keyword can now have additional text
- No language changes that I know of;
Note that Delphi 2007 is a non-breaking release, DCU's from D2006 will work unchanged in D2007; - (The .NET 'personality' of 2007 introduced generics)
- Enhanced records;
- operator overloading;
static
methods and properties;- class helpers;
- FastMM is the default memory manager;
strict
private/protected visibility keyword;final
keyword for virtual methods;{$METHODINFO}
directive;
for ... in
loops,inline
keyword- Wildcard in uses statement allowed
- nested types
- nested constants
{$REGION}
/{$ENDREGION}
directives
- three additional compiler warnings:
- Unsafe_Type,
- Unsafe_Code, and
- Unsafe_Cast. These warnings are disabled by default, but can be enabled
- new compiler directive
{$WARN UNSAFE_CODE ON}
- Overloads of routines that format and parse numbers, date-time values, and currency using a
TFormatSettings
structure.
[TCustomVariantType][68]
provides operator overloading for custom variant types- New compiler directives:
{$IFDEF MSWINDOWS}
{$IFDEF LINUX}
{$LIBPREFIX}
{$LIBSUFFIX}
{$LIBVERSION}
{$MESSAGE 'message'}
{$SetPEFlags}
- Support for
{$IF}{$ELSE}
compiler directives - Compiler hinting directives:
experimental
,deprecated
,library
,platform
(but without additional text for deprecated) - Variant is no longer based on COM but changed to be CLX compatible, COM based variant renamed to
OLEVariant
- Typed constants cannot be assigned to (Override with
{$J+}
) - Enumerated types can be assigned an explicit value (cf C++);
- Interface properties
- Support for calling
varargs
external functions (but only for thecdecl
calling convention) - custom variants
No new language features, but:
- Dynamic arrays
LongWord
andInt64
;Cardinal
is an UINT32 (before it was unsigned 31-bit value)Real
takes 8 bytes and is the same asdouble
(previously it was 6 bytes);- Override with the new
{$REALCOMPATIBILITY ON}
compiler directive; REAL48
replaces the old 6-bytereal
;
- Override with the new
- Support for
resourcestrings
- Method overloading
- Default parameters
{$EXTERNALSYM}
and{$NODEFINE}
directivesimplements
keyword for properties
- Wordbool, longbool and bytebool store
true
as-1
instead of 1 (Boolean is unchanged) - Components must be installed using
packages
. - Assertions.
out
parameters.Widestring
interface
anddispinterface
keyword and COM (dispid
) support.
- Support for 32-bit;
Ansistring
replacesshortstring
as the default string typeCurrency
Variant
(for interop with OLE automation).- Threading support and
ThreadVar
keyword. - 4 byte data is 4 byte aligned new
packed
keyword overrides this behavior; - TDateTime starts at
1899/12/30
under D1 it started at0000/00/00
- new
finalization
keyword register
andstdcall
calling conventions added.packed
keyword.
Just for complement the answer of Johan check this entry on my blog List of changes between versions of Delphi (Since Delphi 5)
and the excellent page The TIndex
which list most of the new features since delphi 2005 and resources about each one.
The jedi.inc file used by the Dephi JEDI project exposes a series of feature defines. If your project is MPL-compatible, you could even use it for feature detection and save yourself the trouble of reinventing that particular wheel.
For example, it defines SUPPORTS_FOR_IN
if the compiler supports enumerators. One could wrap your enumerator code in an IFDEF
checking for that define rather than checking for a particular compiler version.
'developer tip' 카테고리의 다른 글
PHP에서 self :: $ bar와 static :: $ bar의 차이점은 무엇입니까? (0) | 2020.08.04 |
---|---|
2 차원 배열에 대한 포인터 만들기 (0) | 2020.08.04 |
C ++ SFINAE 예제? (0) | 2020.08.04 |
HTML“overflow : auto”와“overflow : scroll”의 차이점 (0) | 2020.08.04 |
Subversion 상태 기호 "~"는 무엇을 의미합니까? (0) | 2020.08.04 |