Comment on Show HN: Zedis – A Redis clone I'm writing in ZigparentComments−throwawaymaths11mochecked array bounds is memory safety.−lyu0728211moRuntime bounds checking, but only in Debug/ReleaseSafe builds, besides there are many other types of memory safety issues left unaddressed.−throwawaymaths11moRuntime bounds checkingCompile time slice bounds checking is generally not a thing, since the length is not known until runtime. Its still safe.but only in Debug/ReleaseSafe buildsSo, the default build modes?Istg zig should just eliminate releasefast and releasesmall and force you to opt in on a function by function basis.
Comments
checked array bounds is memory safety.
Runtime bounds checking, but only in Debug/ReleaseSafe builds, besides there are many other types of memory safety issues left unaddressed.
Compile time slice bounds checking is generally not a thing, since the length is not known until runtime. Its still safe.
So, the default build modes?
Istg zig should just eliminate releasefast and releasesmall and force you to opt in on a function by function basis.