<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">2017-03-25 5:40 GMT-03:00 Sven Barth via fpc-pascal <span dir="ltr"><<a href="mailto:fpc-pascal@lists.freepascal.org" target="_blank">fpc-pascal@lists.freepascal.org</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class=""><p>Am 24.03.2017 19:55 schrieb "Michael Van Canneyt" <<a href="mailto:michael@freepascal.org" target="_blank">michael@freepascal.org</a>>:<br>
><br>
><br>
><br>
> On Fri, 24 Mar 2017, African Wild Dog wrote:<br>
><br>
>> Hello,<br>
>><br>
>> I need to write a code compatilble with both free pascal and delphi using<br>
>> the old style RTTI.<br>
>> What are the diferences between delphi's and free pascal's approach/types?<br>
>><br>
>> I took a look at delphi's and fpc's TypInfo unit and it looks like the<br>
>> types/functions are compatible.<br>
><br>
><br>
> They are. There is one dereference on Delphi which is not present in fpc,<br>
> although in fpc trunk, this additional dereference is there. If you use the<br>
> standard functions you should not notice this.</p>
</span><p>The binary data of RTTI added before 3.1.1 now has the double indirection, but the Delphi-compatible "field" names have only a single indirection for backwards compatibility (they are properties to the double indirection fields). RTTI data added in 3.1.1 only has the double indirection.<br>
So this difference needs to be kept in mind and will always result in ifdefs for RTTI code that handles both Delphi and FPC.</p>
<p>Regards,<br>
Sven</p>
<br></blockquote><br></div><div class="gmail_quote">Thanks for the clarifications.<br><br></div><div class="gmail_quote">Regards<br></div></div></div>