Destroys the String object and frees its memory.
Result := String_destroy(StringObject)
Parameters
| StringObject |
The String object to use for the current operation. |
Return Value
True (1) if the String was actually
destroyed,
or False (0) if the String was not destroyed (see 1 below).
Remarks
The object will not be destroyed
if:
- The lock count for
StringObject is more than one. In this case, the lock count for
StringObject will be decreased by one, and the function returns false to
indicate that the object still exists.
- StringObject is NULL (0 or blank) - returns the empty string to
indicate an error.
Related
String_new
String
Examples
;Creates a new String initialized to "Hello World!"
myString := String_new("Hello World!")
;Destroys myString and frees its memory
Result := String_destroy(myString)
Homepage | Wrappers