[fpc-pascal] Does MACRO work in this case?

David Emerson dle3ab at angelbase.com
Thu Sep 8 23:27:11 CEST 2016


On 09/08/2016 10:08 AM, silvioprog wrote:
> Hello,
>
> Looking an alternative to solve the problem I've talked at this topic
> <http://lists.freepascal.org/pipermail/fpc-pascal/2016-August/048635.html>,
> I've tried to solve it declaring a macro named "TIStringComparer.Ordinal":

Macros can only replace identifiers, the dot breaks it.

I would make something like,

_TIStringComparer_dot_Ordinal

and then you can use the definition you proposed.

I'm in the habit of naming macros with a leading underscore, as I don't 
name anything else that way and it makes it easy to identify them.

~David.





More information about the fpc-pascal mailing list