Freitag, 14. Juli 2017

Which Delphi Language Features are necessary?

Long time ago I was very satisfied with (Turbo)-Pascal.


Everything was fine! My world full of Records, (Fixed)Arrays and Shortstring has made me happy.


There was no need for a Database - I could read and write my Records - as easy as it could be - with blockread and blockwrite...

At this time I was able to write any program I wanted. (for the Kids: Program was the name in these days, today you would call it App)

Then "suddenly" records where bad and I "had to" use classes...


Too Bad... No block-read/write any more.. At this time you had to use Streams... (It finally leads to the same call, but "nobody" knows this...) 


Next Step: You could do fancy things with class operators and implicit. So back to Records?


Then, "suddenly" classes are bad and you have to code against Interfaces to decouple things for Unittests. Have you ever done Unittest in these "old" days?

As time goes by, new compilers were ignored... Delphi 2007 could be used for everything... Windows, Windows-Server(ISAPI.DLL) and ASP.NET...

Sometimes I took a look at new compilers, but without ASP.NET and this new very bad thing called Unicode,  I ignored  them.

So let's jump a few years into mobile development... Many new stuff...
Zero based Unicode Strings - no more Ansi- or Shortstrings, ARC, ARM, 64 Bit, Attributes, Generics, TPL and more...

After 6 years of development - using "new" language features - this features become so handy that I hate every hour of programming old apps with Delphi 2007.

Unbelievable, have you tried "cool stuff" without Generics, lately? Not using generics is like doing the same stuff over and over again. In the old day's we called it copy&paste (OK, Generics is doing copy&paste internally, but it feels better).
And what's about Unit-Test? Are you still using a Hello-World-One-Button-Apps with a Button labeled "Button1" on it to test new Source-Code?

Testdriven-Development - That is the right workflow to speed up development. Of course with Testinsight as you can read in my blogpost from April.


Do you want to see the power of Testdriven-Development - visit my Session at Forentage 2017.

Using new language features? All I can get...