[fpc-devel] Pointer type declaration issue

Sven Barth pascaldragon at googlemail.com
Wed Nov 10 19:57:57 CET 2010


On 10.11.2010 19:46, Thaddy wrote:
> Hi,
>
> When I was adapting KOL for 2.5.1 (trunk) I noticed a delphi
> incompatibility:
>
> PSomeType = ^TMySomeType;
> TMySomeType = tagSometype;
>
> This doesn't compile. I have to change this to
>
> TMySomeType = tagSometype;
> PSomeType = ^TMySomeType;
>
> It potentially breaks a lot of code that is syntactically correct for
> Delphi.
>
> Btw, I have worked around it by changing this for kol.pas by hand.
>
> Is this a documented issue or should I submit a bugreport?

Can you please provide an example? The following code compiles for 
2.4.0, 2.4.2rc1 and 2.5.1 (from the weekend):

=== source begin ===

program pointertest;

type
   tagSomeType = Integer;

   PSomeType = ^TMySomeType;
   TMySomeType = tagSomeType;


begin

end.

=== source end ===

Regards,
Sven



More information about the fpc-devel mailing list