In our previous episode, Graeme Geldenhuys said: > > I'm converting a project from Sibyl (a old OS/2 IDE implement in > SpeedSoft Pascal). > > Below is the code I'm trying to convert to Free Pascal. I see FPC has a > PString type, but not FreePString() or NewPString(). Searching the FPC > source code, I found the FP Text IDE using PString all over. The FP Text > IDE uses this... <some PString var> := NewStr(<string>);
> Do I need this when I use String = AnsiString in my projects? Or can I > simply do the following assignment: _Title := @NevValue; If you want to ansistringify, assume that pstring as a whole is ansistring, and remove all pointers and let ansistrings automatic maintenance work. Be careful with newstr, there are multiple versions of it. (a TP and Delphi version) see http://wiki.freepascal.org/Textmode_IDE_development#ansistringification Don't ever include objects and sysutils in the same unit. _______________________________________________ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal