Inlined ‘Self’-changing type helpers over values accessed by dereference either do not work or cause internal errors.
While trying to fix #39841 (by changing something randomly and seeing if it works) I tried to compile [`tests/webtbs/tw38122.pas`](https://gitlab.com/freepascal.org/fpc/source/-/blob/main/tests/webtbs/tw38122.pp) and got an ICE on the line 72:
```pascal
px^.sub(100); //and this works as well.
```
Then I remembered I had `-OoAUTOINLINE`, but quickly found an offending function whose manual inlining also fails perfectly, and built a simpler example:
```pascal
{$mode objfpc} {$typedaddress on} {$modeswitch typehelpers}
type
XType = double;
XTypeHelper = type helper for XType
procedure Add(x: XType); inline;
end;
procedure XTypeHelper.Add(x: XType);
begin
self += x;
end;
var
x: XType;
begin
x := 0;
(@x)^.Add(1);
if x <> 1 then begin writeln('x = ', x, ', expected 1'); halt(1); end;
writeln('ok');
end.
```
Compiling this for `x86_64-win64` with floating-point `XType` gives `Internal error 200109227`.
Compiling this for `i386-win32` with floating-point `XType` gives `Internal error 200306031`.
Compiling this with integral (or even `record`, with corresponding modifications) `XType` proceeds, but running fails:
```
x = 0, expected 1
```
Probably related and can be fixed _(one day)_ together with #39841, as my #38122-reintroducing patch fixes this as well.
issue