[fpc-devel] Peephole optimizer tai class change proposals

J. Gareth Moreton gareth at moreton-family.com
Wed Oct 6 06:20:53 CEST 2021

Would you approve something like this, Jonas?  I admit it's not properly 
tested yet, but I'm descending from TLinkedListItem (and the descendant 
class can itself be descended from) and the TAOptObj class handles 
allocation and cleanup of extra information.  I'm not sure how practical 
it is, but I'm taking advantage of the linked list system by allowing 
tai objects to have more than one extra information object associated 
with it.


I hope you can view it!

It might be worth changing the defintion of optinfo from Pointer to 
TExtraOptInfo (the TLinkedListItem descendant), but I don't know if this 
may break something that's already present.

One thing I did miss was a "typ" field for TExtraOptInfo so you can look 
up to see what kind of object it is without relying on ClassType etc, 
but I don't know where and how to define such an enumeration because the 
different types would be platform-dependent.  All I can think of 
currently is an include file for each platform, which comes with its own 

Gareth aka. Kit

This email has been checked for viruses by Avast antivirus software.

More information about the fpc-devel mailing list