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 17548 - [REG2.072.0] Forward reference error with scope function parameters #6934
Conversation
…s" because it introduced a regression, see https://issues.dlang.org/show_bug.cgi?id=17548 This reverts commit 60f622f, reversing changes made to 9492814.
… part of reverting dlang#6001 This reverts commit 40fc716, reversing changes made to 3cec8aa.
…ear that they are not meant to override DSymbol.semantic*. Rework of dlang#6001 which caused regression issue 17548.
Thanks for your pull request, @JohanEngelen! 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
|
What's the problem with overriding it? It looks strange to have two different semantic2() functions. |
Indeed. Before #6001, there were two different (but identically named) semantic* functions for a Module. #6001 tried to resolve it by making the Module.semantic* override Dsymbol's. But that apparently broke things. So I reverted that. But now with the revert, a different test ( |
Thanks for looking into it Johan. This fixes my particular case, but struct S2 {
// void bar(int arg = .fwdref1.cnst) {}
S1 s;
import fwdref2;
} Importing itself is contrived, but it could be importing a fwdref3 module that imports fwdref2 and it would be the same. |
Note: I just wanted to unbreak things that got broken by my PR. Now it looks like there is a bigger problem lurking, which does need a proper fix, rather than a revert of #6001. :( |
Still helped :)
Always that feeling with that kind of issue. I pushed a tentative one line fix but fearing it may miss the bigger picture I wanted to see other analysis/suggestions. |
Any idea what caused the regression? Looks a bit like |
This PR