-
Notifications
You must be signed in to change notification settings - Fork 424
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
Compilation failure for promotion and named-expression #11225
Comments
@vasslitvinov : here's the bug we briefly emailed about. Edit: it is not blocking me in any way. |
The behavior has changed to
which is static Symbol* leadingArg(PromotionInfo& promotion, CallExpr* call) {
int i = promotion.formalToActualOpMod;
// Operators might have a different number of formals than provided actuals.
// In this case, the promotedType array access needs to be adjusted to account
// for the offset.
for_actuals(actual, call) {
if (i < 0) {
i++;
continue;
}
if (promotion.promotedType[i++] != NULL)
return symbolForActual(actual);
}
INT_ASSERT(false); // did not find any promoted things
return NULL;
} |
If the assertion is removed, it seems like the behavior is very similar to that in the OP, so maybe not much has changed here... :( |
Since Michael mentioned it would be nice to get this working in Dyno, I've double checked that it works (it does!). #26464 locks down the test (though it does not fix the issue in production). |
In production, the issue (presumably) persists. However, in Dyno everything looks like it works as we'd expect. So, locking down the test case to ensure subsequent changes to Dyno don't break it. Trivial, will not be reviewed. ## Testing - [x] dyno tests
Summary of Problem
The following program fails to compile due to the use of a named-expression in a promoted expression:
The compiler fails with the output:
The text was updated successfully, but these errors were encountered: