cvar external symbol name

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

cvar external symbol name

Free Pascal - General mailing list
Do cvars not allow external symbol names like functions do? With function I can declare a name but for cvar I'm getting an error.

  PyBaseString_Type:PPyTypeObject; cvar; external name 'somename';


Regards,
        Ryan Joseph

_______________________________________________
fpc-pascal maillist  -  [hidden email]
https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: cvar external symbol name

Jonas Maebe-3
On 21/11/2019 19:40, Ryan Joseph via fpc-pascal wrote:
> Do cvars not allow external symbol names like functions do? With function I can declare a name but for cvar I'm getting an error.
>
>   PyBaseString_Type:PPyTypeObject; cvar; external name 'somename';

The only thing cvar does is to mangle symbol name using the default
C-style name mangling. Specifying an explicit symbol name would just
overwrite whatever effect "cvar" has, so combining both is useless and
rejected.


Jonas
_______________________________________________
fpc-pascal maillist  -  [hidden email]
https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: cvar external symbol name

Free Pascal - General mailing list


> On Nov 21, 2019, at 3:40 PM, Jonas Maebe <[hidden email]> wrote:
>
> The only thing cvar does is to mangle symbol name using the default
> C-style name mangling. Specifying an explicit symbol name would just
> overwrite whatever effect "cvar" has, so combining both is useless and
> rejected.

Thanks I see now.

Btw just because I have your attention I made a bug report (https://bugs.freepascal.org/view.php?id=36333) that's ObjC related in case you didn't see it.

Regards,
        Ryan Joseph

_______________________________________________
fpc-pascal maillist  -  [hidden email]
https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal