Liste des Groupes | Revenir à cl c |
On 6/22/2024 8:58 AM, Richard Damon wrote:On 6/22/24 8:42 AM, olcott wrote:On 6/22/2024 5:13 AM, Richard Harnden wrote:
The tighter you specify something, the less scope there is for optimisations and generating more efficient code. It's a tradeoff. C and C++, as languages aimed at (amongst other uses) generating efficient code, have design decisions that give more flexibility to the compilers rather than specifying the details of how implementations must work.It seems pretty stupid to allow gaps in the semantics of C++ programs. Simply specify that the order of evaluation is left to right unless:>>I would say that this would indicate that you are insufficiently
competent with the C programming language.
>
It seems you are the one that doesn't know the C programing language. After all, you didn't know about the unordering of sub-expressions, or that this can lead to undefined behavior.
(a) Otherwise specified such as operator precedence rules.
(b) Derives the same result as left to right ordering.
Les messages affichés proviennent d'usenet.