-
Notifications
You must be signed in to change notification settings - Fork 10.5k
[cxx-interop] Implement operator[] for value return types (SR-14351). #36688
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
Conversation
@zoecarver @egorzhdan Still working on cleaning up the tests. So far I kinda copied Egor's tests for the reference version. Stay tuned. |
I haven't reviewed this, but just kicking off tests. |
@swift-ci test |
Build failed |
ab1938a
to
1c1c6ff
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.
This mostly looks good to me, thanks!
@swift-ci please smoke test. |
e94e5f8
to
cb464d5
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.
This mostly looks great! except for the case when operator[]
returns a pointer.
test/Interop/Cxx/operators/member-inline-module-interface.swift
Outdated
Show resolved
Hide resolved
cb464d5
to
4947e34
Compare
4947e34
to
b4dda83
Compare
b4dda83
to
c60e1d0
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.
The logic all looks good to me but I have a few more comments, sorry ;)
3f7a871
to
17b1a05
Compare
c1e7f82
to
d20b25d
Compare
@swift-ci please smoke test |
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.
This looks great!
We'll also need to run the Windows CI before merging (I can't trigger it myself).
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.
Sorry, one final comment. Other than that, it looks good to me! Are you able to commit yourself?
@swift-ci please test Windows. |
d20b25d
to
67492b9
Compare
Thanks @egorzhdan @zoecarver ! |
@swift-ci please smoke test. |
This builds on top of the work of Egor Zhdan. It implements `T operator[]` and does so largely by taking a path very much like the `const T &operator[]` path.
67492b9
to
864b3a4
Compare
Can someone kick off the Windows CI for me again? I just rewrote the name mangling in the silgen test based on some runs from a Windows build. |
@swift-ci please test Windows platform |
@zoecarver @compnerd Is the CI Busted? I don't see any results for mac/Linux and Windows has a bunch of failures building llvm with
Can we rerun? |
@swift-ci please test Windows platform |
@swift-ci please smoke test macOS. |
@swift-ci please smoke test Linux. |
The test |
Fix in #36833 |
This builds on top of the work of Egor Zhdan's PR. It implements
T operator[]
and does so largely by taking a path very much like theconst T &operator[]
path.