[fpc-devel] [patch] fpdoc linear writer ResolveLink fix

Marco van de Voort marcov at stack.nl
Fri Aug 27 13:16:54 CEST 2010

In our previous episode, Graeme Geldenhuys said:
> > What is the pos() case meant to solve?  If relative link starts with the
> > current modules unit name, then try package.relativelink?
> I did some tests and compared output files generated. I only found 4
> incorrectly resolved links in the current fpdoc version (RTL docs, dos
> unit). Removing the if pos(..)=1 block fixes the problem.

Maybe. But it seems to effectively disable  module.identifier resolution
(for module<>currentmodule).  So while it may not be the most used
functionality, the question is why it must be (effectively) removed.

> Other than than, RTL, FCL and fpGUI documentation output was all identical.
> On a side note, the current version (timed with EpicTimer) was slightly
> fast because it needs to do less recursive calls, but the difference was
> only a few milliseconds in each case.

Did you compare html? It has own code for a lot, and you changed this in
dglobals, not some dwlinear/ipf only module.
> I attached a patch to the original bug report to remove the "if pos(..)=1"
> check.

I'll look at stuff tonight or somewhere during the weekend. 

Could you btw explain the logic behind the canweexit hack? I don't fully
understand why underscores are now equal to points. Won't this cause
problems for people that use unit names with underscores? 

If this is an IPF limitation, why is it done to a global module?

Specially if users are using whole words like generics_collection or
something else whose fragments might clash with other identifiers now.

More information about the fpc-devel mailing list