Il 16/06/23 15:02, Tomas Hajny via fpc-pascal ha scritto:
If you compile with -CO, you should get at least a hint (if you enable
displaying them, of course):
I believed that -Co was enough. I'll add -CO to the debug options.
Thanks.
Giuliano
___
On 2023-06-16 13:46, Giuliano Colla via fpc-pascal wrote:
Il 16/06/23 13:36, Peter B via fpc-pascal ha scritto:
Yes. Assigning a 64bit integer to a 32bit one is fine as long as the
range is within bounds.
Range of a variable can only be checked at run time.
I can understand that. But the com
Il 16/06/23 13:36, Peter B via fpc-pascal ha scritto:
Yes. Assigning a 64bit integer to a 32bit one is fine as long as the
range is within bounds.
Range of a variable can only be checked at run time.
I can understand that. But the compiler generates quite a number of
warning for potential lo
On 16/06/2023 11:55, Giuliano Colla via fpc-pascal wrote:
Is that the intended behavior of compiler?
Yes. Assigning a 64bit integer to a 32bit one is fine as long as the range is
within bounds.
Range of a variable can only be checked at run time.
___
I made a stupid error. My code:
TFileObj = Class(TObject)
[snip]
Size: Integer;
[snip]
end;
procedure TForm1.FillDir(FileData : TSearchRec);
...
FFIleObj.Size := FileData.Size;
...
but TSearchRec structure is:
TRawbyteSearchRec = Record
[snip]
Size : Int64;