[fpc-devel]array of char

Pápai András APapai at mol.hu
Fri Sep 29 09:42:21 CEST 2000


> I found an error.
> Source:
> 
> const
>  CharsDes1:array[0..383]of char=
>   '0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF'+
[...]
> 
> The program just writes the first 255 characters and
> the other characters instead of write zero codes.
> 
> I think it's a bug because the 'string' isn't equal 
> 'array[0..x]of char'.

This works with PChar type:

const
 CharsDes1:PChar=
  '0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF'+

Andras




More information about the fpc-devel mailing list