Sujet : Re: Function calls
De : ram (at) *nospam* zedat.fu-berlin.de (Stefan Ram)
Groupes : comp.std.cDate : 04. Oct 2023, 18:52:11
Autres entêtes
Organisation : Stefan Ram
Message-ID : <call-20231004185102@ram.dialup.fu-berlin.de>
References : 1
ram@zedat.fu-berlin.de (Stefan Ram) writes:
. There's also a section "Function calls" in a recent draft.
I expect that this section says something similar, to the effect that
during the evaluation of a function call, control is transferred to
the called function, but I was not able to find such wording!
Now, some might say that C references "ISO/IEC 2382:2015,
Information technology — Vocabulary" which defines "call".
But this (at least in the second edition) defines a "call"
to be an /instruction/, not a runtime event.
The C specification uses the wording "before the actual call",
which wording requires a call to be a runtime event.
So, although "ISO/IEC 2382" then (in its second edition)
explains that a call is an instruction to "transfer control
from one module to another" it does not blend in well -
and it still does not tell us from which "module" to which
"module" control is transfered in the case of a call in C.