fpc/tests/test/units/sysutils/tsscanf.pp
florian 0d79442d0f + sscanf
git-svn-id: trunk@604 -
2005-07-09 22:34:26 +00:00

19 lines
268 B
ObjectPascal

{$mode objfpc}
{$h+}
uses
sysutils;
var
e : extended;
s : string;
l : longint;
begin
sscanf('asdf 1.2345 1234','%s %f %d',[@s,@e,@l]);
if (e<>1.2345) or
(l<>1234) or
(s<>'asdf') then
halt(1);
// writeln(s,' ',e,' ',l);
writeln('ok');
end.