aboutsummaryrefslogtreecommitdiff
path: root/Testing/Semantic/t5-3.p
diff options
context:
space:
mode:
Diffstat (limited to 'Testing/Semantic/t5-3.p')
-rw-r--r--Testing/Semantic/t5-3.p18
1 files changed, 18 insertions, 0 deletions
diff --git a/Testing/Semantic/t5-3.p b/Testing/Semantic/t5-3.p
new file mode 100644
index 0000000..6494ae0
--- /dev/null
+++ b/Testing/Semantic/t5-3.p
@@ -0,0 +1,18 @@
+(* ERROR: function passed wrong number/type of arguments *)
+program main( input, output );
+ var b: integer;
+ var y: real;
+ var a: array[1 .. 13] of integer;
+ var z: array[1 .. 13] of real;
+
+ function foo(a: integer; x: real): integer;
+ begin
+ foo := a
+ end;
+begin
+ b := foo(y,b) + foo(b,y,10)
+end.
+
+
+
+