<p style="padding:0 0 0 0; margin:0 0 0 0;">I tried your function in FPC 3.0.0 in mode ObjFPC and it returns False for string 'E1/E2/etc'.</p>
<p style="padding:0 0 0 0; margin:0 0 0 0;"> </p>
<p style="padding:0 0 0 0; margin:0 0 0 0;">V.</p>
<p style="padding:0 0 0 0; margin:0 0 0 0;">______________________________________________________________<br />
> Od: steveg <steveg@nevets.com.au><br />
> Komu: "FPC-Pascal users discussions" <fpc-pascal@lists.freepascal.org><br />
> Datum: 24.02.2016 00:57<br />
> Předmět: [fpc-pascal] Possible bug in Numeric test<br />
></p>
<p style="padding:0 0 0 0; margin:0 0 0 0;">Not sure if this is considered a bug or not :)<br />
<br />
I have found this function returns TRUE if passed 'E1/E2/etc'<br />
I am guessing it is seeing the 'E' as exponent<br />
<br />
<br />
function IsNum( const sSrc :string ) :boolean;<br />
var<br />
Code :integer;<br />
Num :real = 0;<br />
begin<br />
Num := Num;<br />
Val(sSrc, Num, Code);<br />
Exit( Code = 0 );<br />
end;<br />
<br />
Thanks - SteveG<br />
_______________________________________________<br />
fpc-pascal maillist - fpc-pascal@lists.freepascal.org<br />
<a href="http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal">http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal</a></p>