Home » Software Development
Lock keyword (templates)
This is a follow-up on the post about the “Lock keyword” emulation in Delphi. Just created 2 templates that you can use in your Delphi code to speed-up writing: [download#34] [download#35] Drop them into X:\Program Files\CodeGear\RAD Studio\6.0\ObjRepos\Code_Templates\Delphi directory…
Read More »Strings in Delphi (continued)
It seems the more you look, the more you find. There are a few interesting points in how strings are handled in Delphi; I’ve talked before about the particularities of String type in Delphi, so I’ll not touch…
Read More »The Lock keyword
What I miss the most from C# is the lock keyword. Unfortunately Delphi doesn’t (yet) have such a “feature” so we’re stuck making calls to synchronization objects manually. It’s not a big problem actually but can get quite…
Read More »Delphi “Future”
The title is probably a bit misleading. I’m not going to talk about the “future of Delphi” rather about the concept of “future evaluation” in Delphi. You might have heard about the Delphi Prism product that Embarcadero/CodeGear is…
Read More »String reverse tests
This post will be a short one. Just giving a general recommendation for people doing String processing in Delphi – use PChar or ^Char for that. I have made a simple test program that reverses a very big…
Read More »Strings, PChars and reference counting
Hi folks, in today’s post I will continue with reference counting specifics of Delphi in the particular case of Strings. We’ll start with a small example: What will the output of this program be? The obvious result (the…
Read More »C++ Builder TypeInfo alternative.
I bet most Delphi developers know about TypeInfo operator. It provides type information somehow similar to reflection in Java or .NET (of course a lot more limited). Take this simple example: It will simply write “Byte” on the…
Read More »That stupid garbage collector
I’ve heard this phrase a few times in regards to Delphi’s reference counting mechanics. Before continuing with this post please note — Delphi doesn’t have a Garbage Collector (as Java or .NET)! It uses Reference Counting as part…
Read More »Delphi 2009: reference to
It’s probably not news anymore but Delphi 2009 supports anonymous methods out of the box. To be able to support them, CodeGear developers added a new type of a “pointer to a method” called a managed method reference:…
Read More »Generics.Defaults: Bug
There is a bug in Generics.Defaults unit in Delphi 2009. If you read my previous post: Generic Defaults you should know already about the “3 bytes long” data types and how are those passed as const parameters to…
Read More »