[stable] Fix #22543 - Cannot index AA literal in global-variable initializer#22552
[stable] Fix #22543 - Cannot index AA literal in global-variable initializer#22552kinke merged 2 commits intodlang:stablefrom
Conversation
|
Thanks for your pull request and interest in making D better, @kinke! 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 referencesYour PR doesn't reference any Bugzilla issue. If your PR contains non-trivial changes, please reference a Bugzilla issue or create a manual changelog.
|
| e0 = Expression.combine(e0, call); | ||
|
|
||
| if (arrayBoundsCheck(sc.func)) | ||
| if (sc.func && arrayBoundsCheck(sc.func)) |
There was a problem hiding this comment.
Maybe checking sc.ctfe or so would be better?
There was a problem hiding this comment.
Hmm, I expected the added test with global inside a function body to fail with this condition, but it works.
Edit: Hmm, that even worked with v2.112.0.
No description provided.