-
-
Notifications
You must be signed in to change notification settings - Fork 608
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
Issue 15094 - __traits(getMember) fails when the source is a struct/class field #5215
Conversation
| @@ -87,6 +88,19 @@ extern (C++) static void collectUnitTests(Dsymbols* symbols, AA* uniqueUnitTests | |||
| } | |||
| } | |||
|
|
|||
| // strip off expression context | |||
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.
Some more explanation of what this function does and why is needed.
|
56e96ae
to
87d6efa
Compare
| // It might really be an Expression or an Alias | ||
| ta.resolve(loc, sc, &ea, &ta, &sa); | ||
| ta.resolve(loc, sc, &ea, &ta, &sa, (flags & 1) != 0); |
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.
Do we have a named flag for this instead of 1?
|
Added ddtailed comments, and fixed auto-tester failure. |
I did not apply all formatting/stylistic changes.
…ct/class field If `TemplateInstance.semanticTiargs` is called from `TraitsExp`, do not strip off the contexts of argument expressions: 1. give `true` to the `intypeid` parameter of `Type.resolve` call. 2. leave `TOKdotvar` and `TOKdottd` as-is.
I did not apply all formatting/stylistic changes.
|
Attempted Revival at #7341 |
https://issues.dlang.org/show_bug.cgi?id=15094
If
TemplateInstance.semanticTiargsis called fromTraitsExp, do not strip off the contexts of argument expressions:trueto theintypeidparameter ofType.resolvecall.TOKdotvarandTOKdottdas-is.