blob: e6e440c328fa24b8fc2aab387b33e680405de328 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
|
Program Example4;
Uses strings;
{ Program to demonstrate the StrCopy function. }
Const P : PCHar = 'This is a PCHAR string.';
var PP : PChar;
begin
PP:=StrAlloc(Strlen(P)+1);
STrCopy (PP,P);
If StrComp (PP,P)<>0 then
Writeln ('Oh-oh problems...')
else
Writeln ('All is well : PP=',PP);
StrDispose(PP);
end.
|