New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[intro.execution] Is it possible to clarify the second bullet for immediate subexpressions #4525
Comments
@jensmaurer Please examine the conclusion. It seems that in the most major implementations, they consider such an implicitly call as the constructs that appear in the lexical part that corresponds to the expression E instead of these functions that would be dynamically invoked by #include <iostream>
struct A{
A() noexcept(false){
}
};
void fun() noexcept(true){
A a{}; // initialization for `a` implicitly invokes A::A()
}
int main(){
std::cout<< noexcept(fun());
} But it's not true, the result indicates the expression So, my conclusion is that
This modification could restrict that these function call should be lexical appears with |
Yes, "immediate subexpression" is intended on the almost-syntax level. |
So, I thik the sentence "which is the part of the full-expression of E" would help to state that meaning. |
It would not, because we use "subexpression" in the definition of "full-expression", thus the definition would become circular. Not good. |
Could we say "which is lexical". Or any other wording as long as that meaning could be read. In addition, AFAIK, it seems there's no conflict if we use full-expression in that sentence. That means, such an implicitly call is never a full-expression. That approach is merely a bit obscure as you said it becomes circular. |
As stated in the definition for immediate subexpressions
Does it refer to the implicit function call that appears in the lexically part of the expression E or any such function call invoked when evaluating the expression
E
? I mean, in the following two examplesIn this example, these implicitly invoked function calls appear in the lexically part of the expression
Test{}.a
.As a contrast, see the second example
In this example, evaluate the postfix-expression, namely the function call
fun()
, will implicitly invoke the constructor and destructor of classT
which appear in its function body.It's unclear what's the intent of the bullet second. These two kinds of understanding have a large difference.
The text was updated successfully, but these errors were encountered: