11 ms·
Well, it has. You just said so, it's (ptr+len). ...it's the philosophy of the C language: There's minimal bloat on the upside, but you have to know what you're
by klingonopera 7y ago
Well, it has. You just said so, it's (ptr+len).
...it's the philosophy of the C language: There's minimal bloat on the upside, but you have to know what you're doing and how to be able get it on the downside.
- pornel 7y agoThat's like saying C doesn't need pointers in the type system, because it already has pointer-sized integers (BCPL actually had that philosophy). Slices greatly improve interfaces. Especially if you want to return a (sub)slice of something, C doesn't have any non-clunky solution.