With a correctly defined language and a carefully written application it is possible to instruct the compiler to add code that automatically checks for things like attempts to read uninitialized local variables or to access memory outside the memory block a pointer points to.
The advantage of this method is that with the right kind of programming language it has the potential to make a piece of software completely unexploitable, because all security holes in the software are converted to denial of service attack vectors. Another advantage is direct exposure of security bugs in software.
The major disadvantage is severe performance drop associated with this. To obtain perfect protection the entire operating system (except the kernel which is written in the assembly language) must be compiled with this rigorous checking code added.
This security provision does not work with the C programming language which allows nasty things like converting integers to pointers (note that pointer arithmetic is OK for this security provision, also conversions from pointer to integer are also OK), but the language can be redesigned to allow it to work (what is one of reasons why the P programming language was invented).
This security provision also does not work with the assembly language and the nature of the assembly language prevents it from being redesigned to make the security provision work. Therefore assembly language
When a process is running code that has not the automatic rigorous checking code present (so called exploitable code), that process of course becomes exploitable, but the exploitability of other processes is not affected unless they use services provided by the exploitable process. In any case the exploitable code is not prevented from working. Therefore the automatic rigorous checking code is compatible with proprietary programs. However libraries with exploitable code make any program using them explitable so proprietary libraries can seriously diminish the protection offered by the automatic rigorous checking code.