fpc/tests/test/tforin14.pp
paul 5752be310d compiler:
- fix for-in loop for string const array
  - add some test from Alexander S. Klenin
(issue #0014990)

git-svn-id: trunk@14041 -
2009-11-04 12:07:42 +00:00

25 lines
285 B
ObjectPascal

{mode objfpc}
{$apptype console}
type
T = array [1..3] of Integer;
procedure P(a: array of T);
var
r: T;
i: Integer;
begin
for r in a do
begin
for i in r do Write(i, ' ');
Writeln;
end;
end;
const
r1: T = (1,2,9);
r2: T = (3,4,5);
begin
P([r1, r2]);
end.