[Overview][Constants][Types][Classes][Procedures and functions][Variables][Index] Reference for unit 'sysutils' (#rtl)

DisposeStr

Dispose an ansistring from the heap.

Declaration

Source position: line 0

procedure DisposeStr(

  S: PString

); overload;

procedure DisposeStr(

  S: PShortString

); overload;

Description

DisposeStr removes the dynamically allocated string S from the heap, and releases the occupied memory.

This function is provided for Delphi compatibility only. AnsiStrings are managed on the heap and should be preferred to the mechanism of dynamically allocated strings.

For an example, see DisposeStr.

Errors

None.

See also

NewStr

  

Allocate a new ansistring on the heap.

AppendStr

  

Append one ansistring to another.

AssignStr

  

Assigns an ansistring to a null-terminated string.

The latest version of this document can be found at lazarus-ccr.sourceforge.net.