3 ms·
I think the big problem with objects is that they're just not the common denominator: e.g., image files/formats are going to be byte streams. That, and getting
by deathanatos 3y ago
I think the big problem with objects is that they're just not the common denominator: e.g., image files/formats are going to be byte streams.
That, and getting the world to agree on object formats is like pulling teeth, it seems. E.g., WASM just wanted to add a string type, which OUGHT TO¹ be simple (use UTF-8) … but alas.
JSON? Not enough types. YAML? Doesn't matter if it's good, nobody likes YAML. Etc.
And you have to serialize them to bytes somewhere along the line; either to transfer their memory representation to another process, or to put them on the network.
I start thinking "Perhaps something could be built on top of byte streams" but that's YAML, JSON, CBOR, take your pick.
¹(this is an RFC 6919 OUGHT TO)
- charcircuit 3y agoI don't understand. Objects existing doesn't mean files can no longer exist. >getting the world to agree on object formats is like pulling teeth In Windows apps agree, Mac app agree, iOS app agree, Android apps agree, Java apps agree. Sending or receiving strings to a system API is common. >And you have to serialize them to bytes somewhere along the line; either to transfer their memory representation to another process, or to put them on the network. Yes, but I'd much prefer if there was the 1 true way an os chooses it to be than each thing inventing its own way.
- GoblinSlayer 3y agoWell, there's dbus. On the other hand if you want a function and not protocol, why would you care what protocol it uses? It might as well be a file. When you call getaddrinfo("localhost"), it reads /etc/hosts - a text file.