2 ms·
Here's an example of how ATS makes a C API safer, similar to the API in the K&R example (it deals with memory/string copying): http://www.bluishcoder.co.nz/2012
by doublec 14y ago
Here's an example of how ATS makes a C API safer, similar to the API in the K&R example (it deals with memory/string copying):
http://www.bluishcoder.co.nz/2012/08/30/safer-handling-of-c-memory-in-ats.html http://www.bluishcoder.co.nz/2012/08/30/safer-handling-of-c-...
ATS provides all the low level hackery that C can do but allows more information to be encoded in types to ensure that is safe. It also provides high level features from functional programming languages like higher order functions, pattern matching, etc.