5 ms·
The obvious flipside of this is that those C programs written for Burroughs never had any chance of running on anything but Burroughs. The only difference is th
by hexane360 8y ago
The obvious flipside of this is that those C programs written for Burroughs never had any chance of running on anything but Burroughs. The only difference is that C offloads the effort of portability onto the user, whereas other languages at least attempt to make it portable in the compiler.
- pjmlp 8y agoWhat?! Since when did Burroughs had a C compiler? NEWP was and is more than enough, while being much safer.
- bitwize 8y agoSafety is a hardware feature of the Burroughs architecture. C is no less safe there than NEWP.
- pjmlp 8y agoSure it is, NEWP only allows for C style unsafely on UNSAFE blocks, clearly tagged by the system administrator as allowed for execution. So not only is lack of safety expressed on the type system, something that C doesn't have, it also allows someone explicitly stating it is ok to risk its execution.
- bitwize 8y agoYou're assuming that C runs on the Burroughs the way it commonly does on x86, with arbitrary access to all memory within its address space. This is not specified in the C standard, and it's not the case for C on the Burroughs. In particular, since C was not the OS implementation language, but was mainly uaed to port programs from other architectures, the C heap lived entirely within a single memory block and C code could not interfere with other programs. See: https://en.wikipedia.org/wiki/Burroughs_large_systems_descriptors#Usage_in_compilers https://en.wikipedia.org/wiki/Burroughs_large_systems_descri...
- pjmlp 8y agoIt still corrupts their own memory space, which is the whole point of C being unsuitable for any kind of safe software. C also does not interfere with other programs on its own turf, UNIX.
- saagarjha 8y agoWhy not? As long as your program is standards-compliant, it should work on any computer with a working C compiler…
- hexane360 8y ago- integral sizes aren't standard - little vs big endian - signed int layout - float layout - includes vary - bit field implementations vary - loads of undefined and implementation-defined behavior
- saagarjha 8y agoThe only thing that can change is implementation-defined behavior, and this can be detected and guarded against. Undefined behavior cannot exist in a standards-compliant program.