[fpc-devel] How to move this, but in FPC 32bit?

Ozz Nixon ozznixon at gmail.com
Wed Nov 14 13:44:21 CET 2018


Thank you all ... I am on the road, when I get back, I will track down
TUnitHeader, TObjectTypeDefinition, TOrdinalTypeDefinition - and post those
structures. My problem was changing the above to simple:
   PreviousUnitAddressOffset:=TUnitHeader.PreviousUnitAddress;

does not work, I think they are constants - I will have to dig back through
the code. (It's from 1995, written by Anders Hejlsberg, so it does a lot of
odd ASM things).

Ozz

On Tue, Nov 13, 2018 at 1:31 PM Ralf Quint <freedos.la at gmail.com> wrote:

> On 11/12/2018 7:37 AM, Ozz Nixon wrote:
>
> I have these last couple of lines to port to FPC -Mdelphi, but everything
> I try fails...
>
> Asm
>     MOV  PreviousUnitAddressOffset,
> TUnitHeader.PreviousUnitAddress
>     MOV  PreviousLibraryUnitAddressOffset,
> TUnitHeader.PreviousLibraryUnitAddress
>     MOV  AncestorTypeDefinitionOffset,
> TObjectTypeDefinition.AncestorTypeOffset
>     MOV  OrdinalTypeDefLowerLimitOffset,
>  TOrdinalTypeDefinition.LowerLimit
>     MOV  OrdinalTypeDefUpperLimitOffset,
>  TOrdinalTypeDefinition.UpperLimit
> end;
>
> Well, as others already mentioned, it is hard to give proper advice
> without having a reproducible piece of code.
>
> Just looking at the snippet above, I would start with questioning if there
> isn't a more "Pascal way" to do this, whatever this piece of code is trying
> to accomplish...
>
> Ralf
>
>
> <https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient&utm_term=icon> Virus-free.
> www.avast.com
> <https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient&utm_term=link>
> <#m_-1587466564115926972_DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2>
> _______________________________________________
> fpc-devel maillist  -  fpc-devel at lists.freepascal.org
> http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-devel
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freepascal.org/pipermail/fpc-devel/attachments/20181114/023923ec/attachment.html>


More information about the fpc-devel mailing list