Re: Faster way of making long string?



On Tue, 26 Apr 2005 21:56:46 +0200, Ekkehard Domning <edo@xxxxxxxx>
wrote:

<snip>

>I made a test with this and Str() is much faster than IntToStr. This was
>surprising for me.

If you have a Pro or Enterprise edition then right click on IntToStr(
then select 'Find Declaration'

It will send you on a right old chase through SysUtils.pas

Doing the same on Str( just opens System.pas
- no source - some sort of compiler magic

Quite interesting

Mostly - I think the speed is down to not creating new strings
- but the FormatBuf code is ... not exactly to the point

It would be handy if Delphi provided some sort of Strings Created
statistic for profiling
.



Relevant Pages