what exactly is string length?

Computermatronic computermatronic at gmail.com
Fri Apr 2 04:54:07 UTC 2021


On Friday, 2 April 2021 at 04:49:22 UTC, mw wrote:
> So you mean inside the writeln() call, the 0s are skipped?
>
> Well, if I use `string t` as filename, it will try to looking 
> for a file called:
>
> "head-abc\0\0\0-tail" instead of just "head-abc-tail" ?
>
> or it's platform dependent?

I would imagine that it's platform dependant, but given most 
platforms adhere to the C ABI, and C string are null terminated, 
you'd end up looking for a file called "head-abc".


More information about the Digitalmars-d-learn mailing list