On 26 May 2004 at 1:17, Waldek Hebisch wrote:
I noticed that the following FPC code (claimed to be BP compatible) is not accepted by GPC:
function b:string; begin b[1] := ' ' end;
BP accepts this, and so does Delphi. I agree that GPC should too.
GPC accepts this: function b:string; begin result[1] := ' ' end;
Similarely FPC accepts:
type a = record i, j : integer end; function b(i, j: integer) : a; begin b.i := i; b.j := j end;
BP doesn't accept this. If gives this error: "Error 34: Invalid function result type."
However, Delphi accepts it. GPC doesn't. But GPC accepts this: function b(i, j: integer) : a; begin result.i := i; result.j := j end;
So, GPC is nearly there already.
Best regards, The Chief -------- Prof. Abimbola A. Olowofoyeku (The African Chief) web: http://www.greatchief.plus.com/