-
Notifications
You must be signed in to change notification settings - Fork 1.9k
C++: Handle field initialization via NSDMI in IR generation #21391
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
base: main
Are you sure you want to change the base?
Changes from all commits
5aabd90
07603a8
59c27a2
68039ec
09f930f
9e60e12
b91a52a
e986d89
22eda4e
f3fc80a
b554d7d
4a637cb
0f44d6a
49c5cc0
db7c619
dad517f
346ab9d
ef780c1
ab1f0c1
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,5 @@ | ||
| --- | ||
| category: feature | ||
| --- | ||
| * Added a class `ConstructorDirectFieldInit` to represent field initializations that occur in member initializer lists. | ||
| * Added a class `ConstructorDefaultFieldInit` to represent default field initializations. |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -36,7 +36,8 @@ abstract class TranslatedCondition extends TranslatedElement { | |
| final override Declaration getFunction() { | ||
| result = getEnclosingFunction(expr) or | ||
| result = getEnclosingVariable(expr).(GlobalOrNamespaceVariable) or | ||
| result = getEnclosingVariable(expr).(StaticInitializedStaticLocalVariable) | ||
| result = getEnclosingVariable(expr).(StaticInitializedStaticLocalVariable) or | ||
| result = getEnclosingVariable(expr).(Field) | ||
|
Comment on lines
37
to
+40
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. At some point we should probably have some kind of abstract class thingie instead of having to enumerate all the possible Doesn't have to be now, though, of course!
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Agreed. I like leaving that as a follow-up. |
||
| } | ||
|
|
||
| final Type getResultType() { result = expr.getUnspecifiedType() } | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.