* changed declarations in finah.inc and diskh.inc from ansistring to

rawbytestring
  * DoDirSeparators() and GetDirs() marked as "rtlproc" so they can accept
    non-rawbytestring arguments as their var-parameters

git-svn-id: branches/cpstrrtl@25306 -
This commit is contained in:
Jonas Maebe 2013-08-19 22:04:40 +00:00
parent 65ecd1273d
commit 2da7c3f05c
7 changed files with 12 additions and 12 deletions

View File

@ -17,10 +17,10 @@ Function DiskFree(drive: byte) : int64;
Function DiskSize(drive: byte) : int64;
Function GetCurrentDir : {$ifdef FPC_UNICODE_RTL}UnicodeString{$else}AnsiString{$endif};
Function SetCurrentDir (Const NewDir : AnsiString) : Boolean;
Function CreateDir (Const NewDir : AnsiString) : Boolean;
Function RemoveDir (Const Dir : AnsiString) : Boolean;
Function ForceDirectories(Const Dir: AnsiString): Boolean;
Function SetCurrentDir (Const NewDir : RawByteString) : Boolean;
Function CreateDir (Const NewDir : RawByteString) : Boolean;
Function RemoveDir (Const Dir : RawByteString) : Boolean;
Function ForceDirectories(Const Dir: RawByteString): Boolean;
Function SetCurrentDir (Const NewDir : UnicodeString) : Boolean;
Function CreateDir (Const NewDir : UnicodeString) : Boolean;

View File

@ -346,7 +346,7 @@ begin
Result:=Result+ExtractFileName(DestName);
end;
Procedure DoDirSeparators (Var FileName : PathStr);
Procedure DoDirSeparators (Var FileName : PathStr); {$ifdef FPC_HAS_CPSTRING}rtlproc;{$endif}
VAr I : longint;
@ -371,7 +371,7 @@ end;
if none were found.
}
Function GetDirs (Var DirName : PathStr; Var Dirs : Array of PathPChar) : Longint;
Function GetDirs (Var DirName : PathStr; Var Dirs : Array of PathPChar) : Longint; {$ifdef FPC_HAS_CPSTRING}rtlproc;{$endif}
Var I : Longint;

View File

@ -37,8 +37,8 @@ function ExcludeTrailingPathDelimiter(Const Path: PathStr): PathStr;
function IncludeLeadingPathDelimiter(Const Path : PathStr) : PathStr;
function ExcludeLeadingPathDelimiter(Const Path: PathStr): PathStr;
function IsPathDelimiter(Const Path: PathStr; Index: Integer): Boolean;
Procedure DoDirSeparators (Var FileName : PathStr);
Procedure DoDirSeparators (Var FileName : PathStr); {$ifdef FPC_HAS_CPSTRING}rtlproc;{$endif}
Function SetDirSeparators (Const FileName : PathStr) : PathStr;
Function GetDirs (Var DirName : PathStr; Var Dirs : Array of PathPChar) : Longint;
Function GetDirs (Var DirName : PathStr; Var Dirs : Array of PathPChar) : Longint; {$ifdef FPC_HAS_CPSTRING}rtlproc;{$endif}
function ConcatPaths(const Paths: array of PathStr): PathStr;

View File

@ -293,7 +293,7 @@ Type
{$define PathPChar:=PWideChar}
{ Read filename handling functions declaration }
{$i finah.inc}
{$define PathStr:=AnsiString}
{$define PathStr:=RawByteString}
{$define PathPChar:=PAnsiChar}
{ Read filename handling functions declaration }
{$i finah.inc}

View File

@ -25,7 +25,7 @@
{ Read disk function implementations }
{$i disk.inc}
{$undef SYSUTILSUNICODE}
{$define PathStr:=AnsiString}
{$define PathStr:=RawByteString}
{$define PathPChar:=PAnsiChar}
{ Read filename handling functions implementation }
{$i fina.inc}

View File

@ -183,7 +183,7 @@ begin
end;
function ExpandUNCFileName (const filename:string) : string;
function ExpandUNCFileName (const filename:rawbytestring) : rawbytestring;
{ returns empty string on errors }
var
u: unicodestring;

View File

@ -102,7 +102,7 @@ begin
end;
function ExpandUNCFileName (const filename:string) : string;
function ExpandUNCFileName (const filename:rawbytestring) : rawbytestring;
var
u: unicodestring;
begin