7 ms·
That’s a good reason. And a weird restriction (with 2000’s glasses on designing an ergonomic language).
by alkonaut 7y ago
That’s a good reason. And a weird restriction (with 2000’s glasses on designing an ergonomic language).
- int_19h 7y agoGiven the circumstances of C's birth, it was, in many ways, optimized to be ergonomic for the compiler writer. If you don't ever need to return structs, then you can always just use the same register to hold the return value. Similarly, if there are no struct-typed arguments, then each argument is either a register, or a single machine word on the stack (C did other things for the latter - e.g. consider the conversion rules for functions called without being declared).
- pjmlp 7y agoQuite to be expected given its ancestry, BCPL was originally designed only to bootstrap CPL.