Bart via fpc-devel <fpc-devel@lists.freepascal.org> schrieb am Sa., 9. Jan. 2021, 05:17:
> On Fri, Jan 8, 2021 at 9:00 PM Sven Barth via fpc-devel > <fpc-devel@lists.freepascal.org> wrote: > > >> It seems I cannot use a stand-alone function that is declared in the > >> implementation of the unit? > > > Generics are a stream of tokens that is reparsed when specialized. > Functions declared in the implementation section are simply not available > then thus its forbidden right away. This is Delphi compatible. > > Thanks for explaining this. > The errormessage is probably technically correct, but for me it might > be a little more informative (so that I can tell what I did wrong). > Right click the error message in Lazarus, then click "Help". For me a dialog with the following text appeared: "A generic declared in the interface section of a unit must not reference symbols that belong solely to the implementation section of that unit." The *why* is not important for users. Those that are interested can ask, just like you did. Regards, Sven >
_______________________________________________ fpc-devel maillist - fpc-devel@lists.freepascal.org https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-devel