3 ms·
> Plan 9 C implements C by attempting to follow the programmer’s instructions Which, I might add, is a very silly thing to say. A programmer's intent and thei
by colanderman 8y ago
> Plan 9 C implements C by attempting to follow the programmer’s instructions
Which, I might add, is a very silly thing to say. A programmer's intent and their written code are two very different things. How one maps to the other is defined only by the C standard, which says nothing about emitting specific assembly instructions, but only about the ultimate effect of code on memory.
The Plan 9 compiler deciding to pessimize your code because it assumes you actually meant for the code to be interpreted as portable assembly rather than a high-level description of a computation is kind of presumptuous. At that point it's just a different language with different (albeit compatible) semantics.
- aap_ 8y agoPlan 9 C is a different language than ANSI C anyway.
- MisterTea 8y agoHell of a lot cleaner too.
- wahern 8y agoNot really. C99 adopted most (all?) of their extensions, including anonymous union and structure members, compound literals, long long, and named initializers. Interestingly, with the exception of long long, these are the features that effectively forked C and C++.