<div dir="auto"><div class="gmail_quote" dir="auto"><div dir="ltr">Am Sa., 10. Nov. 2018, 14:47 hat Ryan Joseph <<a href="mailto:ryan@thealchemistguild.com">ryan@thealchemistguild.com</a>> geschrieben:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><br>
<br>
> On Nov 10, 2018, at 7:22 PM, Florian Klämpfl <<a href="mailto:florian@freepascal.org" target="_blank" rel="noreferrer">florian@freepascal.org</a>> wrote:<br>
> <br>
> If you "export" a generic taking a const from a unit, this info has to be stored in the ppu.<br>
<br>
Can you show a test case I could use to see where this is triggered in the compiler? I don’t even know where to begin looking.<br></blockquote></div><div dir="auto"><br></div><div dir="auto">The important part are the ppuwrite and ppuload methods that are provided by tstoreddef, tstoredsym and tstoredsymtable and overridden by most of their descendants. E.g. tstoreddef itself is also dealing with the generic parameters. </div><div dir="auto"><br></div><div dir="auto">And for a test: declare the generic in one unit, specialize it in another and compile twice. Usually things go boom if you messed up something. </div><div dir="auto"><br></div><div dir="auto">By the way: When adding/changing data that is written to the PPU increase the PPUVersion constant in the ppu.pas unit (there is no backwards compatibility for PPUs) and also adjust the ppudump utility in compiler/utils/ppudump. </div><div dir="auto"><br></div><div dir="auto">Regards, </div><div dir="auto">Sven </div><div class="gmail_quote" dir="auto"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"></blockquote></div></div>