GExperts 1.37 (commit 875, but no tag yet) now supports Delphi XE6 and XE5, and ahost of older Delphi versions. Binary downloads are available at Download | GExperts
Experimental GExperts Version 1.37-2014-04-12 released » twm’s blog which is interesting because it shows you how to install GExperts when there is no official installer for it yet. An alternative is to use the batch files that are in my GExperts downloads page. Note I am working on a continuous integration server that will build a couple of open source Delphi projects (the plan is to include GExperts, DUnit and a few others) that makes it easier to publish those builds.
Once every while, one of your StackOverflow answers gets an edit suggestion that is really valuable.
This case it was Edwin Yip who suggested to emphasize the difference between TStringBuilder and TStringList (adding characters versus lines).
Too bad that freshly 10k user Makoto showed he hates bold emphasis, intentional property casing and post signatures by removing the added value (there is so much emphasis he could remove on other answers to warrant at least a day time job).
I needed to modify some code that had been amended from the Delphi TParser class (which parses DFM files, but can be amended to other sources as well), so here are some links I found during my research:
Be sure to watch the presenter Stefan Eggermont (StackOverflow, Twitter, LinkedIn, GitHub, FOSDEM, website www.legacycode.nl) as this kind of analysis (that is also possible for other languages and tools) can highly speedup your work.
Even in unsuspiciously looking code, the wit statement can bite you, especially if you need to do refactoring and (because of that) introduce two names in the same scope.
Whilst upgrading the code to remove the Containers unit (its not supported on NextGen platforms, so I have to make things work with Generics.Collections instead, (bye bye D7 support for this code) and refactor a couple stupidities in my original design (they always creep in, don’t they) I ended up with two class members of the same name. The with block then looked OK but I was in fact not access the member I thought I was.
Every once in a while you have multiple threads or processes wanting to write a short message to the same log file. Append then will give you an I/O error 32 (ERROR_SHARING_VIOLATION), but the below small routine will sleep a bit while retrying a couple of times.
in $I- mode, you access the IOResult to obtain the results of those I/O operations
IOResult gets the result of the last failed operation (if any) or zero if none failed
IOResult clears the underlying storage to zero
$IFOPT checks for a certain state of a compiler flag
You can store the state of $OPT in a temporary conditional define
Note there are a few tables of codes you can get back through IOResult as basically you can get many GetLastError results in IOResult as well: Read the rest of this entry »