mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-07 03:47:59 +02:00
29 lines
450 B
ObjectPascal
29 lines
450 B
ObjectPascal
{$ifdef fpc}{$mode objfpc}{$endif}
|
|
|
|
uses
|
|
sysutils;
|
|
|
|
const
|
|
fname = 'tw1479.tmp';
|
|
|
|
ThisDir = '.'+DirectorySeparator;
|
|
var
|
|
fn : string;
|
|
f : text;
|
|
begin
|
|
assign(f,fname);
|
|
rewrite(f);
|
|
writeln(f,'hello');
|
|
close(f);
|
|
|
|
fn:=FileSearch(fname,PathSeparator);
|
|
writeln('found: ',fn);
|
|
if fn<>fname then
|
|
halt(1);
|
|
fn:=FileSearch(ThisDir+fname,PathSeparator);
|
|
writeln('found: ',fn);
|
|
if fn<>ThisDir+fname then
|
|
halt(1);
|
|
erase(f);
|
|
end.
|