1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30
program tb0540; {$mode objfpc} {$H-} {$Q+,R+} uses sysutils; var a:string; b:string[63]; c:char; w:word; begin a:=''; b:=''; w:=257; try c:=a[w]; writeln('string[255] failure'); halt(1); except end; try c:=b[w]; writeln('string[63] failure'); halt(2); except end; end.