-
-
Notifications
You must be signed in to change notification settings - Fork 609
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
Fix Issue 17307 - [REG2.072.0][ICE] TypeBasic::implicitConvTo #7199
Conversation
|
Thanks for your pull request, @JinShil! We are looking forward to reviewing it, and you should be hearing from a maintainer soon. Some tips to help speed things up:
Bear in mind that large or tricky changes may require multiple rounds of review and revision. Please see CONTRIBUTING.md for more information. Bugzilla references
|
|
The error message sounds correct to me, as D's grammar doesn't support neither inline typedefs, nor inline struct variables (declaring a structure and variables of that type in a single declaration). So really there's another way to use anonymous structs or unions in D, except as members of other aggregates. |
|
I think this is fighting the symptoms, but a type pointer |
|
You should also add the test somwhere to the fail_compilation test suite. |
Done
Done |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks.
It's a bit annoying that code coverage marks this PR as bad as it just removes a line. The percentage drops indeed, but the number of uncovered lines stays the same.
|
The theory of dealing with compilation errors is not to attempt to recover from them, but to 'poison' anything that depends on an AST node that has an error in it. This is the rationale of This PR is trying to recover from the error by putting the erroneous A fix more in keeping with the error design in the compiler is to 'poison' the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Set errors instead, per my other comment.
|
@JinShil when submitting a bug fix PR, please note in bugzilla the PR url. This helps prevent someone else from wasting their time preparing a fix for an issue if there already is an outstanding PR. Thanks! (I already took care of it for this one.) |
Done. I hope my changes are what you intended. |
| @@ -55,6 +55,9 @@ extern (C++) abstract class AttribDeclaration : Dsymbol | |||
|
|
|||
| Dsymbols* include(Scope* sc, ScopeDsymbol sds) | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also need to do the overrides of include().
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
|
Good! Well done. |
Fix Issue 17307 - [REG2.072.0][ICE] TypeBasic::implicitConvTo cherry-picked-by: Martin Krejcirik <mk@krej.cz>
This fixes the ICE, but there may still be an underlying problem with the semantics.
Output for...
... is now...
I'd be happy to add a test case, but I first need confirmation that that is the expected output.