<div dir="auto"><div><div class="gmail_quote"><div dir="ltr" class="gmail_attr">Florian Klämpfl via fpc-devel <<a href="mailto:fpc-devel@lists.freepascal.org">fpc-devel@lists.freepascal.org</a>> schrieb am So., 8. Nov. 2020, 22:18:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Am 07.11.2020 um 23:00 schrieb Bart via fpc-devel:<br>
> Hi,<br>
> <br>
> Type<br>
> SubRange = Chr(1)..Chr(2);<br>
> begin<br>
> end.<br>
> <br>
> This compiles in TP 6.0 and Delphi 7.0, but fpc doesn't.<br>
> <br>
> Free Pascal Compiler version 3.3.1 [2020/09/26] for i386<br>
> Copyright (c) 1993-2020 by Florian Klaempfl and others<br>
> Target OS: Win32 for i386<br>
> Compiling test.pas<br>
> test.pas(2,14) Error: Identifier not found "Chr"<br>
> test.pas(2,28) Error: Error in type definition<br>
> test.pas(5) Fatal: There were 2 errors compiling module, stopping<br>
> Fatal: Compilation aborted<br>
> <br>
> Is this a bug?<br>
<br>
Yes, it should work. It got broken somewhere during some generic work (at least I think so). Sven, can you please have a <br>
look?<br></blockquote></div></div><div dir="auto"><br></div><div dir="auto">I don't know if it's related to generics that this does not work, but at least with my changes in r47353 it now behaves consistent with e.g. Ord(). </div><div dir="auto"><br></div><div dir="auto">Regards, </div><div dir="auto">Sven </div><div dir="auto"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
</blockquote></div></div></div>