Re: [fpc-pascal] small bug with pass-by-reference on array elem

2008-06-29 Thread Jonas Maebe
On 28 Jun 2008, at 23:55, David Emerson wrote: {$mode objfpc} procedure assign_it (out x : longint); begin x := 7; end; var a : array [0..1] of longint; b : longint; begin assign_it (b); // no warning assign_it (a[1]); // errant warning issued end. This bug has already

[fpc-pascal] small bug with pass-by-reference on array elem

2008-06-28 Thread David Emerson
I would post this directly to the bugs database, but I've never received my confirmation email (I've tried a couple times now, perhaps my ISP greylisting is blocking it?) - If a param is passed-by-reference to a function without being initialized first, a warning is issued by the compiler. -