[fpc-pascal] Possible RTFM question: is there something like an IsRootPath() function?

Bart bartjunk64 at gmail.com
Mon Aug 20 00:17:20 CEST 2012


Hi,

Does fpc have a function that determines if a given paths is the root
(e.g. '/' in Linux, 'F:\' in Windows)?
I could not find such a thing.

The Delphi converter from Lazarus needs such a function, and currently
I wrote a crude one which is ifdef-ed in the source code, which we
would like to avoid if possible.
(See: http://svn.freepascal.org/cgi-bin/viewvc.cgi/trunk/converter/convertdelphi.pas?root=lazarus&r1=38276&r2=38275&pathrev=38276
)

Bart



More information about the fpc-pascal mailing list