4 ms·
The problem is that C without pointers is extremely limiting. At least in C++ you'd have references left. More generally I don't think you can really "patch" a
by simias 6y ago
The problem is that C without pointers is extremely limiting. At least in C++ you'd have references left.
More generally I don't think you can really "patch" a language to make it safe. It's going to leak unsafety all over the place. Consider a simple `printf("%s", 12);` which is obviously broken but doesn't really trigger any kind of memory unsafety at the call site. You might argue that "%s" is a pointer in disguise, but if you ban C strings and arrays you won't have a lot left to work with (besides in this case the string pointer is perfectly valid, it's the format string that's incorrect).