A quick post on a small but hugely useful little language feature in Oxygene… if expressions.
A brief post on a long standing omission in type checking in Pascal and the limitations of Range Checking as applied to the problem.
I have posted before about new language features introduced in a way that does not adhere to the (admittedly quite notional) “Spirit of Delphi”. It’s time for another one, this time inspired by a post by Paul Klink of the ADUG.
Lars Fosdal responded to my previous post suggesting a way of implementing string support in a case-like construct (but not actually a case statement) using generics and anonymous methods. All very clever, but way, way too complicated and – if you don’t mind me saying so – as ugly as sin into the bargain (imho – ymmv). For simple cases [sic], it is actually relatively straightforward to uses strings in a case statement.
Eric Grange (resurrector of the increasingly interesting looking DWS project) recently posted about a new idea he has had for the DWS engine, which in turn gave me an idea, or rather, prompted me to come up with what I think may be a new spin on an old one.
A welcome new language feature in Delphi 2010 is the introduction of attributes, as previously found in .NET languages. However I am slightly disappointed that the language implementation is also very close to that found in C# and other .NET languages and not more in keeping with what I would consider The Spirit Of Delphi.