Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
The semantics of Byte() Let-coercion depend on the source’s value type and the destination’s declared type:
|
Source Value Type |
Destination Declared Type |
Semantics |
|---|---|---|
|
Byte() |
Resizable Byte() |
The result is a copy of the source Byte array. |
|
Byte() |
String or String * length |
The binary data within the source Byte array is interpreted as if it represents the implementation-defined binary format used to store String data. Even if this implementation-defined format includes a prefixed length and/or end marker, these elements are not read from the Byte array and MUST instead be inferred from the String data. The result is the string produced.
This coercion never raises a runtime error. If the byte array is uninitialized, the result is a 0-length string. If binary data in the array cannot be interpreted as a character, or if the character specified is cannot be represented on the current platform, that character is output in the String as a ? character. Any trailing bytes leftover at the end of the byte array that could not be interpreted are discarded. |
|
Byte() |
Any numeric type, Boolean or Date |
The result is undefined. |
|
String |
Resizable Byte() |
The result is a copy of the implementation-defined binary data used to store the String value, excluding any prefixed length and/or end marker. |
|
Any numeric type, Boolean or Date |
Resizable Byte() |
Runtime error 13 (Type mismatch) is raised. |