Eclipse behavior for
Function OPEN

Description:

The following external-format designators are supported:

Character Formats:

Integer formats:

Integer element-types are upgraded to either signed-byte or unsigned-byte of size 1, 8, 16 or 32. signed-byte is equivalent to (signed-byte 32), and unsigned-byte is equivalent to (unsigned-byte 32).

When the :DEFAULT external-format is specified, the actual external-format used is based on the specified element-type, and can be examined with stream-external-format. The value is :ASCII when element-type is a subtype of base-char, :MULTI-BYTE when element-type is a subtype of unicode-char, and :BIG-ENDIAN when element-type is a subtype of integer.

When the :DEFAULT element-type is specified, the actual element-type used is based on the actual external-format, and can be examined with stream-element-type. The value will be the most restricted element-type listed above, for the given external-format.

See Also:

"Characters in Eclipse" (particularly the "Interaction With Streams" section), *default-element-type*, stream-element-type, stream-external-format.

Notes:

unicode-char is a strict subtype of character in Eclipse. However, no behavior is currently defined for any character that is not also a unicode-char. Accordingly, open will treat character element-type arguments as though they were specified as unicode-char. This may change in future releases, and programmers are encouraged to specify the precise value of element-type required. The actual stream-element-type reflects the correctly downgraded value.

:MULTI-BYTE and :ASCII formats are the same externally when the default (i.e. the "C") locale is used and only ASCII characters are involved.

:MULTI-BYTE is also known as :UTS-8.

On some platforms, the operating system implementation of wcstombs() and mbstowcs() does not correctly handle 4 octet unicode characters (UCS-4). On these platforms, the actual stream-element-type for :MULTI-BYTE streams may be downgraded to ucs-2-char.

The units of position used in file-position, file-length, and file-string-length are 8-bit bytes for the :MULTI-BYTE external-format. For all other external-formats, the units of position measure one element-type.


[Previous] [Next] [Up] [Documentation Contents] [Eclipse Home Page]