What are the problems with using generics and anonymous methods in Delphi 2009?

I would like to start using generics and an anonymous method, mainly to find out what this means and why I would like to use them.

Having Delphi 2009, I often read that generics and anonymous methods are not fully implemented or erroneous, which was fixed in Delphi 2010.

I would like not to wonder if this was wrong in my mistake or in Delphi 2009, every time something does not work as I expect.

My question is:
What specific problems will I have when using generics and anonymous methods in Delphi 2009?
What should i avoid?

+6
generics anonymous-methods delphi delphi-2009
source share
2 answers

What problems do you have? Well, if everything compiles, then you are usually fine. This is not a bad issue related to codecs, and is no longer a problem with codegen. This is because creating actual code from common templates tends to cause the compiler to go dark and you get internal errors.

What should i avoid? Due to the fact that you have not noticed what you should avoid, you are trying to use generics in the D2009 and expect them to work. Update 3 fixed a lot of things, but not all. In Delphi 2010, much more has been fixed, and in most cases, generics are used mainly if you are not trying to mix generics with packages. They are still working to use this part correctly. For now, I would recommend just waiting a few more weeks (presumably) until the next version appears and is updated. In any case, they will have generics that work just as well as the rest of the systems.

+6
source share

You can use Quality Central . It allows you to search by specific criteria (e.g. version) and keywords to show you any problems reported and their status. Remember that some of the private elements may have been fixed in a later release.

+5
source share

All Articles