[fpc-devel] Omit hint/warning for a fixed-size array
wkitty42 at windstream.net
wkitty42 at windstream.net
Fri Aug 31 14:32:57 CEST 2018
On 08/30/2018 03:46 AM, Ondrej Pokorny wrote:
> Hello,
>
> is there a way not to get a "Variable xyz does not seem to be initialized"
> hint/warning for a fixed-size array?
>
> program Project1;
> uses Classes;
> var
> Buffer: array[0..255] of Byte;
what about
Buffer: array[0..255] of Byte = [0];
would that or something similar work? i do similar in several of my programs but
i don't have any arrays in use in them...
eg:
MyMeanMotnStr : string = '';
MyMeanMotion : double = 0.0;
ModeDIAG : boolean = False;
obs_location : vector = (0,0,0,0);
sstringlen : longint = 0;
i know one solution has already been posted but thought of this one earlier when
i first read your post... i just delayed in writing this until now :/
--
NOTE: No off-list assistance is given without prior approval.
*Please keep mailing list traffic on the list unless*
*a signed and pre-paid contract is in effect with us.*
More information about the fpc-devel
mailing list