Главная страница
Top.Mail.Ru    Яндекс.Метрика
Текущий архив: 2008.08.24;
Скачать: CL | DM;

Вниз

TComponentName = type string;   Найти похожие ветки 

 
savyhinst ©   (2008-07-16 17:43) [0]

Здраствуйте.
Подскажите пожалуйста, что значит конструкция

 TComponentName = type string;

,Что было найдено мною в Classes.pas
,и чем она отличается от

 TComponentName = string

Спасибо за внимание.


 
tesseract ©   (2008-07-16 17:51) [1]

Справочник даже открыть лень ?


 
savyhinst ©   (2008-07-16 17:52) [2]

Какой справочник? я впервые в жызни такое вижу


 
Palladin ©   (2008-07-16 18:04) [3]

который по F1 находится


 
Ega23 ©   (2008-07-16 18:24) [4]


> savyhinst ©   (16.07.08 17:43)



When you declare a type that is identical to an existing type, the compiler treats the new type identifier as an alias for the old one. Thus, given the declarations

type TValue = Real;
var
 X: Real;
 Y: TValue;

X and Y are of the same type; at runtime, there is no way to distinguish TValue from Real. This is usually of little consequence, but if your purpose in defining a new type is to utilize runtime type information--for example, to associate a property editor with properties of a particular type--the distinction between "different name" and "different type" becomes important. In this case, use the syntax

type newTypeName = type type

For example,

type TValue = type Real;

forces the compiler to create a new, distinct type called TValue.



Страницы: 1 вся ветка

Текущий архив: 2008.08.24;
Скачать: CL | DM;

Наверх




Память: 0.47 MB
Время: 0.016 c
15-1215444473
buzb
2008-07-07 19:27
2008.08.24
Как ограничить интернет-траффик?


1-1197120105
A.L.E.X.A.N.D.E.R
2007-12-08 16:21
2008.08.24
Условные переходы в асм-вставках


2-1216663591
TStas
2008-07-21 22:06
2008.08.24
Забыл, как зовут ф-цию :(


15-1214935991
DVM
2008-07-01 22:13
2008.08.24
А у кого нибудь ICQ работает, но через сторонний клиент?


1-1197018990
Rav
2007-12-07 12:16
2008.08.24
Как преобразовать TField.DisplayWidth в ListView.Column[x].Width?