I just noticed this by accident and I don't understand. Why does " x := @r; "
compile? I would expect it to fail like the next line where I cast to the
explicit type.
type
TMyRec = record end;
PMyRec = ^TMyRec;
var
x: PByte;
r: TMyRec;
begin
x := @r;// works
x := PMyR
Hairy Pixels via fpc-pascal schrieb am
Mi., 9. Aug. 2023, 04:59:
> I just noticed this by accident and I don't understand. Why does " x :=
> @r; " compile? I would expect it to fail like the next line where I cast to
> the explicit type.
>
> type
> TMyRec = record end;
> PMyRec = ^TMyRec;
> v