summaryrefslogtreecommitdiff
path: root/ecomp-c/test1.e
diff options
context:
space:
mode:
authorAndreas Baumann <mail@andreasbaumann.cc>2020-05-29 19:37:08 +0200
committerAndreas Baumann <mail@andreasbaumann.cc>2020-05-29 19:37:08 +0200
commitde5d9c5d1b735e95a20a8671d38697f1c7e638ea (patch)
treec36e67bb004671324b1f847c3a57a6da32530bf7 /ecomp-c/test1.e
parent8c3ad4c4acc3212ba5d1ff0a3aada3e714dad071 (diff)
downloadcompilertests-de5d9c5d1b735e95a20a8671d38697f1c7e638ea.tar.gz
compilertests-de5d9c5d1b735e95a20a8671d38697f1c7e638ea.tar.bz2
added support for strings in ec
Diffstat (limited to 'ecomp-c/test1.e')
-rw-r--r--ecomp-c/test1.e9
1 files changed, 6 insertions, 3 deletions
diff --git a/ecomp-c/test1.e b/ecomp-c/test1.e
index 3ad3bac..f18f847 100644
--- a/ecomp-c/test1.e
+++ b/ecomp-c/test1.e
@@ -8,10 +8,13 @@ const
// integer constant
N, M : integer = 20;
O : integer = N;
- C : character = 'a';
+ C : character = 'A';
// boolean constant
INIT_STATE : boolean = true;
+
+ // string constant
+ S : array 5 of character = "hello";
var
// this is an integer
@@ -24,7 +27,7 @@ var
flag : boolean;
i : integer;
j : character := C;
- s : array 100 of character;
+ s : array 5 of character := S;
begin
a := 1;
@@ -54,5 +57,5 @@ begin
i := i + 1;
end;
- j := 'b';
+ j := 'B';
end