News for hackers. Stuff that matters.
Re:Zig: a system language which prioritizes optimality, safe... by nickpsecurity on Tuesday August 30, 2016 @08:49PM (#12395124)
The desired outcome is a program that either doesn't have the error or crashes safely with a report of exactly how it happened. Not segfaults or undefined behavior in general. The latter are simply one of the consequences of C's design and programming style than anything inevitable or ideal.

It's tradition that failures of a language's safety system to handle memory are "memory, safety issues." However, that they can be used for code injections in some scenarios is even more reason to think of them that way and make our languages prevent them where possible. Quick example:

https://tk-blog.blogspot.com/2009/01/exploitable-userland-nu...

Re:Zig: a system language which prioritizes optimality, safe... by SamReidHughes on Tuesday August 30, 2016 @11:19PM (#12395775)
Yeah, in C you could have a problem if there's a large object, but in that language you already have undefined behavior. Nim is not C, and bounds checking on arrays prevents that. (I am only skimming the docs, so tell me if that is incorrect.)