This is my blog about software development, mountain unicycling, Photography, and stuff I find interesting.
Here are some new useful alias types in Delphi 2009:
Int8 = ShortInt;
Int16 = SmallInt;
Int32 = Integer;
UInt8 = Byte;
UInt16 = Word;
UInt32 = Cardinal;
Hallelujah! I've never successfully remembered the difference between ShortInt and SmallInt for more than a day. Now I don't have to :-)
Indeed, although I can't way I've ever struggled with Byte, Word or Cardinal in the same way and I think I prefer those to UIntN.:)
Good to know. This might be a preparation for Int64
What about UInt64?
> Good to know. This might be a preparation for Int64There already is an Int64 :), have been there since Delphi 6 or 7 (or maybe earlier)
Isn't there also a "NativeInt = Integer" alias.
Yeah, there is a UInt64, Int64, NativeInt and NativeUInt, but they don't appear to be aliases (at least not that are visible in System.pas)
Great! We could each have done this in our code all using somewhat different naming. Much better that CodeGear set a clear standard.