News for hackers. Stuff that matters.
Re:Type-erased generic functions for C: A modest non-proposal by Gibbon1 on Thursday October 03, 2024 @04:05PM (#41734410)
We could fire WG14 and add Walter Brights fix for passing arrays, buffer and slice types. Add phat pointers and types as fist class objects.

If you did that and implemented marking passing size info over function calls then you could probably mechanically convert crappy foo(void *buf, int sz) code to foo(slice_t buf) which would be a lot safer to maintain.

There are no comments on this comment yet.