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
Also expose 'parent' when it's abstract #6876
Also expose 'parent' when it's abstract #6876
Conversation
Thanks for your pull request and interest in making D better, @thaven! We are looking forward to reviewing it, and you should be hearing from a maintainer soon.
Please see CONTRIBUTING.md for more information. If you have addressed all reviews or aren't sure how to proceed, don't hesitate to ping us with a simple comment. Bugzilla references
Testing this PR locallyIf you don't have a local development environment setup, you can use Digger to test this PR: dub run digger -- build "master + phobos#6876" |
8452b92
to
ea157a0
Compare
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.
Tests please
I added a separate test now (and removed the static assert that I originally added in the existing test). The test is a stripped-down version of the actual code I need this change for. It seems it actually works for non-overloaded functions, but fails for overloaded ones. I think I'll need to loop through the overload set to find the correct overload to alias. |
It turns out the problem with overloading is an existing bug and also applies to the |
Created Issue 19715 about the Could this PR move on without that fix (by temporarily commenting out an overload in the test + adding a TODO referencing the issue)? |
Yes, fixing senate issues separately is usually a good idea. |
65bcb11
to
a4d1c62
Compare
a4d1c62
to
47291bb
Compare
Rebased this old PR on current master. Let's see how the tests turn out now. (previous run, long ago, just got stuck somewhere) |
When generating methods to implement e.g. an interface, it is also very useful to have an alias to the (abstract) function being overridden. E.g. to have access to UDAs.