Re:Checked C
by friendzis on Thursday December 22, 2022 @03:20AM
(#34091055)
Statically allocated/sized arrays are relatively easy. The problem is dynamically allocated/sized arrays coupled with pointer "interface", which supports type casting.
[ Parent
| on HN ]
Something smart enough to convert pointer arithmetic to slice expressions is needed. Most C pointer arithmetic is really just slice access.
(Who invented array slices? It was a concept that came along much later than one might have expected.)