Re:A Review of the Zig Programming Language (Using Advent of...
by anonymoushn on Tuesday December 28, 2021 @07:02AM
(#29712924)
Woe be to they who attempt to save Japanese mp3 files on a Linux NAS and read them from a Mac.
[ Parent
| on HN ]
Re:A Review of the Zig Programming Language (Using Advent of...
by chubot on Tuesday December 28, 2021 @11:52AM
(#29715435)
Yeah that's true, but this has nothing to do with the programming language, and everything to do with the file system implementation in the kernel, and the OS APIs.
The programming language can only do so much about this problem, and doing too much is harmful (e.g. Python 3).
The default OS X file system isn't POSIX compliant, which creates a portability issue. In POSIX file systems, filenames are bytes, and file contents are bytes. But that isn't true on OS X.
Re:A Review of the Zig Programming Language (Using Advent of...
by anonymoushn on Tuesday December 28, 2021 @01:04PM
(#29716169)
Agreed all around. "Strings are byte arrays" is imo the right approach to living in a hellworld where programs like filesystems expect you to send them all sorts of different precise arrangements of bytes.