Talk:cpp/concepts
From cppreference.com
I am writing to ask for editing advice.
-
I am thinking of changing the paragraph:
- Every expression required to be equality preserving is further required to be stable, that is, two evaluations of such an expression with the same input objects must have equal outputs absent any explicit intervening modification of those input objects.
- Every expression required to be equality preserving is further required to be stable, that is, to give equal outputs for two evaluations of itself with the same input objects without any explicit intervening modification of those input objects.
-
Strictly speaking, "explicit intervening modification" is still a bit vague. Should it be clarified further?
Studyingegret (talk) 07:08, 25 February 2023 (PST)
- Certainly! The wording will only improve from editing and more accessible presentation. :-) --Space Mission (talk) 07:33, 25 February 2023 (PST)
I think there are many things missing or not accurate in the definition of "equality-preserving". I admit I don't fully understand it (so I can't edit it myself), but here are three problems to mention:
- The "implicit expression variations" in the spec are not mentioned
- "Explicit intervening modification" looks vague
- The concept of the domain of an expression is not mentioned
- "each template type parameter": Confusing, what does equality preservation of expressions have to do with template type parameters? Probably refers to the type parameters of the concept template instead, which are then used in the
requires
-expressions, which is what equality preservation is about.
It would also be better to have some examples. (Should a todo mark be added?) Also, I'm thinking of calling the "operands" (as in the original spec) "base operands", but I'm unsure.