Regarding the proposed Binray Literals Deprecation
rikki cattermole
rikki at cattermole.co.nz
Mon Sep 12 18:19:19 UTC 2022
On 13/09/2022 6:11 AM, Kagamin wrote:
> On Monday, 12 September 2022 at 18:05:14 UTC, rikki cattermole wrote:
>> Escapes require extra processing, more memory usage to display, which
>> is unnecessary for this this type of data.
>
> Hex strings require extra processing too, they aren't WYSIWYG.
They require very little processing and only in the compiler.
> And there
> being lots of small code points I suspect you can even save space by
> using short escapes compared to hex strings.
Keep in mind that hex strings use case is not for string data. It is a
method of getting a whole load of raw bytes directly into the binary
which can be cast to the appropriate type before usage (i.e. struct).
The direct comparison is to array literal syntax ``[123, 14, 72]`` for
which you still have the comma, which adds extra processing to the editor...
More information about the Digitalmars-d
mailing list