[fpc-devel] Overloaded Pos bug

Vincent Snijders vsnijders at quicknet.nl
Fri Sep 12 11:21:17 CEST 2008


petr.kristan at epos.cz schreef:
> In fpc revision 11746 i cannot compile this construction:
> 
> program posx;
> var
>   s, s1: WideString;
> begin
>   Pos(s[1], s1);
> end.
> 
> fpc -vh posx.pas
> Hint: Start of reading config file /etc/fpc.cfg
> Hint: End of reading config file /etc/fpc.cfg
> Free Pascal Compiler version 2.3.1 [2008/09/11] for i386
> Copyright (c) 1993-2008 by Florian Klaempfl
> posx.pas(5,3) Error: Can't determine which overloaded function to call
> ustrings.inc(1524,10) Hint: Found declaration: Pos(UnicodeChar,const UnicodeString):LongInt
> ustrings.inc(1497,10) Hint: Found declaration: Pos(const UnicodeString,const UnicodeString):LongInt
> posx.pas(7) Fatal: There were 1 errors compiling module, stopping
> Fatal: Compilation aborted
> 
> Kylix and about month erlier fpc was ok.
> 

Please, create a bug report.

Vincent



More information about the fpc-devel mailing list