A call to finalize is necessary since the dynamic
array contains long strings. Even if the sample code
only used strings less than 255 in length, it is still
a long string because long string (ansi string) is
delphi's default string type.
--- Rob Kennedy <[EMAIL PROTECTED]> wrote:
> Monir-SCS wrote:
> > Please look at the following code, it is important
> to finalize the
> > tmp variable inside GetArray, here we are setting
> the length once and
> > finialize twice!, or no need to do both
> finalization?
>
> *Neither* is necessary. Remove them both. Dynamic
> arrays are
> automatically released when they go out of scope,
> just like AnsiStrings,
> WideStrings, an interfaces.
>
> --
> Rob
>
__________________________________
Do you Yahoo!?
Yahoo! Small Business - Try our new resources site!
http://smallbusiness.yahoo.com/resources/
-----------------------------------------------------
Home page: http://groups.yahoo.com/group/delphi-en/
To unsubscribe: [EMAIL PROTECTED]
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/delphi-en/
<*> To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/