[fpc-devel] Troubles with FPDOC in 2.5.1 and 2.4.1

Michael Van Canneyt michael at freepascal.org
Fri May 14 13:20:21 CEST 2010


The problem is in supporting the 'depecated' and other modifiers.
I have added support for that, but apparently, it breaks parsing
in other cases (the implementation is rather messy).

Please add bug reports for this, using small code samples.

Also, it is not necessary to report that the compiler compiles it. 
I assume this is the case anyway.

Michael.

On Fri, 14 May 2010, Graeme Geldenhuys wrote:

> This never happened before when I generated fpdoc help for tiOPF. I tried
> now with the latest fpdoc in Trunk (2.5.1) and I get the following errors.
> I then tried with fpdoc from latest 2.4.1 branch and the same thing. The
> last time I generated fpdoc help for the tiOPF project was 2009-05-28 and
> then it worked fine.
>
> Looking at the actual code, I cannot see what the problem is. FPC 2.4.1 and
> FPC 2.5.1 compiles the tiOPF code without such errors.
>
>
> ---------[ fpdoc errors ]------------------
> ../Source/Core/tiVisitorDB.pas(160,16): Expected ";" at token "Identifier
> deprecated"
> ../Source/Core/tiUtils.pas(1371,14): Expected ";" at token "of"
> ../Source/Core/tiStreams.pas(384,5): Syntax error at token "label"
>
> ----------------------------
>
> Here are the actual code snippets. I marked the lines fpdoc reports the
> errors on.
>
> ------------[ tiVisitorDB.pas ]-------------
>  // alias class will be removed soon.
>  TVisOwnedQrySelect = class(TtiVisitorSelect)
>  end deprecated;        // <<-- error reported here
> --------------------------------------------
>
>
> ------------[ tiUtils.pas ]-------------
> function tiGetFileSize(AValue : string): longInt;
> var f: file of Byte;     // <<-- error reported here
> begin
>  AssignFile(f, AValue);
>  Reset(f);
>  result := FileSize(f);
>  closeFile(f);
> end;
> --------------------------------------------
>
>
> ------------[ tiStreams.pas ]-------------
> function MimeEncodeString (const s: AnsiString): AnsiString;
> label                     // <<-- error reported here
>  NothingToDo;
> var
>  l: Cardinal;
> begin
>  if Pointer(s) = nil then
>    goto NothingToDo;
>  l := Cardinal (Pointer (Cardinal (Pointer (s)) - 4)^);
>  SetLength (Result, (l + 2) div 3 * 4);
>  if Pointer (Result) = nil then
>    goto NothingToDo;
>  MimeEncode (Pointer (s)^, l, Pointer (Result)^);
>  Exit; //==>
>
>  NothingToDo:
>  Result := '';
> end;
> --------------------------------------------
>
>
> Regards,
>  - Graeme -
>
> -- 
> fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal
> http://opensoft.homeip.net/fpgui/
>
> _______________________________________________
> fpc-devel maillist  -  fpc-devel at lists.freepascal.org
> http://lists.freepascal.org/mailman/listinfo/fpc-devel
>



More information about the fpc-devel mailing list