Why Isn’t C Memory Safe Yet?(blog.regehr.org)
blog.regehr.org
Why Isn’t C Memory Safe Yet?
http://blog.regehr.org/archives/715
7 comments
The real question is why hasn't a language emerged that is as efficient as C but much safer? Undoubtedly such language is feasible.
I think the Go language people are trying for this:
> Go is an attempt to combine the ease of programming of an interpreted, dynamically typed language with the efficiency and safety of a statically typed, compiled language. It also aims to be modern, with support for networked and multicore computing. Finally, it is intended to be fast: it should take at most a few seconds to build a large executable on a single computer. To meet these goals required addressing a number of linguistic issues: an expressive but lightweight type system; concurrency and garbage collection; rigid dependency specification; and so on. These cannot be addressed well by libraries or tools; a new language was called for. (from http://golang.org/doc/go_faq.html#What_is_the_purpose_of_the... )
> Go is an attempt to combine the ease of programming of an interpreted, dynamically typed language with the efficiency and safety of a statically typed, compiled language. It also aims to be modern, with support for networked and multicore computing. Finally, it is intended to be fast: it should take at most a few seconds to build a large executable on a single computer. To meet these goals required addressing a number of linguistic issues: an expressive but lightweight type system; concurrency and garbage collection; rigid dependency specification; and so on. These cannot be addressed well by libraries or tools; a new language was called for. (from http://golang.org/doc/go_faq.html#What_is_the_purpose_of_the... )
Another approach is to have the safer language compile down to C. This is the approach taken by various Schemes, like Chicken Scheme.
The Stalin Scheme compiler, "often generates code that outperforms handwritten C and Fortran code".[1]
[1] - ftp://ftp.ecn.purdue.edu/qobi/research-statement.pdf
The Stalin Scheme compiler, "often generates code that outperforms handwritten C and Fortran code".[1]
[1] - ftp://ftp.ecn.purdue.edu/qobi/research-statement.pdf
lua seems to be the closest option
Because then it wouldn't be C?