Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
|
|
@ -0,0 +1,22 @@
|
|||
MODULE Concat;
|
||||
|
||||
IMPORT Out,Strings;
|
||||
|
||||
VAR
|
||||
S1:ARRAY 16 OF CHAR;
|
||||
S2:ARRAY 8 OF CHAR;
|
||||
PS1,PS2:POINTER TO ARRAY OF CHAR;
|
||||
BEGIN
|
||||
(* Static *)
|
||||
S1 := "Hello ";
|
||||
S2 := "literal";
|
||||
Strings.Append(S2, S1);
|
||||
Out.String(S1); Out.Ln;
|
||||
(* Dynamic *)
|
||||
NEW(PS1, 16);
|
||||
NEW(PS2, 8);
|
||||
COPY("Hello ", PS1^);
|
||||
COPY("literal", PS2^);
|
||||
Strings.Append(PS2^, PS1^);
|
||||
Out.String(PS1^); Out.Ln;
|
||||
END Concat.
|
||||
Loading…
Add table
Add a link
Reference in a new issue