Show: Object Pascal C++
String to PChar Conversions
From Appmethod Topics
Go Up to Working with Strings
- Long strings are reference-counted, while
- Assigning to a string copies the data, while a
PCharis a pointer to memory.
- Long strings are null-terminated and also contain the length of the string and other information, while
PCharsare simply null-terminated.
Situations in which these differences can cause subtle errors are discussed in the following topics: