[Overview][Constants][Types][Classes][Procedures and functions][Variables] Reference for unit 'System' (#rtl)

FileNameCaseSensitive

OS treatment of filenames is case sensitive.

Declaration

Source position: sysunixh.inc line 47

const FileNameCaseSensitive: Boolean = true;

Description

FileNameCaseSensitive is True if case is important when using filenames on the current OS. In this case, the OS will treat files with different cased names as different files. Note that this may depend on the filesystem: Unix operating systems that access a DOS or Windows partition will have this constant set to true, but when writing to the DOS partition, the casing is ignored.

This constant is part of a set of constants that describe the OS characteristics. These constants should be used instead of hardcoding OS characteristics.

See also

DriveSeparator

  

Character used to separate directory parts.

DirectorySeparator

  

Character used to separate directory parts.

LineEnding

  

Constant describing the current line ending character.

LFNSupport

  

COnstant describing support for long filenames.

PathSeparator

  

Character used to separate paths in a search list

FileNameCaseSensitive

  

OS treatment of filenames is case sensitive.

DefaultTextLineBreakStyle

  

Default line ending style.

Ambiguous use of FileNameCaseSensitive

This symbol seems to have an ambiguous meaning to the RTL.  For example, on Win32 (or go32v2, watcom with long filename support), this symbol is set to True, even though these systems treat filenames differing only in case as the same filename (c:\AutoExec.bat = C:\AUTOEXEC.BAT).

The fact that, on DOS and Windows systems, FileNameCaseSensitive is true only when long filename support is available implies to me that the intent is for the filename handling routines (e.g. FExpand) to preserve the case of filenames.  However, this has the side-effect that routines such as SameFileName also compare filenames case-sensitively, which is incorrect on these systems.

-- Unregistered Visitor on September 19, 2006 01:29 AM (view details)