Skip to content

[cxx-interop] Do not run a test in C++20 mode #65943

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

Merged
merged 1 commit into from
May 16, 2023

Conversation

egorzhdan
Copy link
Contributor

This test is failing on UBI platform in C++20 mode:

Command Output (stderr):
--
<unknown>:0: warning: the '-enable-experimental-cxx-interop' flag is deprecated; please pass '-cxx-interoperability-mode=' instead
<unknown>:0: note: Swift will maintain source compatibility for imported APIs based on the selected compatibility mode, so updating the Swift compiler will not change how APIs are imported
<unknown>:0: warning: the '-enable-experimental-cxx-interop' flag is deprecated; please pass '-cxx-interoperability-mode=' instead
<unknown>:0: note: Swift will maintain source compatibility for imported APIs based on the selected compatibility mode, so updating the Swift compiler will not change how APIs are imported
/home/build-user/swift/test/Interop/Cxx/stdlib/use-std-vector.swift:41:14: error: for-in loop requires 'Vector' (aka 'std.vector<Int32, allocator<Int32>>') to conform to 'Sequence'
    for e in v {
             ^
/home/build-user/swift/test/Interop/Cxx/stdlib/use-std-vector.swift:52:15: error: value of type 'Vector' (aka 'std.vector<Int32, allocator<Int32>>') has no member 'map'
    let a = v.map { $0 + 5 }
            ~ ^~~

This makes sure we don't run this test in C++20 mode until the conformance to CxxSequence is synthesized correctly on UBI.

rdar://109366764

This test is failing on UBI platform in C++20 mode:

```
Command Output (stderr):
--
<unknown>:0: warning: the '-enable-experimental-cxx-interop' flag is deprecated; please pass '-cxx-interoperability-mode=' instead
<unknown>:0: note: Swift will maintain source compatibility for imported APIs based on the selected compatibility mode, so updating the Swift compiler will not change how APIs are imported
<unknown>:0: warning: the '-enable-experimental-cxx-interop' flag is deprecated; please pass '-cxx-interoperability-mode=' instead
<unknown>:0: note: Swift will maintain source compatibility for imported APIs based on the selected compatibility mode, so updating the Swift compiler will not change how APIs are imported
/home/build-user/swift/test/Interop/Cxx/stdlib/use-std-vector.swift:41:14: error: for-in loop requires 'Vector' (aka 'std.vector<Int32, allocator<Int32>>') to conform to 'Sequence'
    for e in v {
             ^
/home/build-user/swift/test/Interop/Cxx/stdlib/use-std-vector.swift:52:15: error: value of type 'Vector' (aka 'std.vector<Int32, allocator<Int32>>') has no member 'map'
    let a = v.map { $0 + 5 }
            ~ ^~~

```

This makes sure we don't run this test in C++20 mode until the conformance to `CxxSequence` is synthesized correctly on UBI.

rdar://109366764
@egorzhdan egorzhdan added the c++ interop Feature: Interoperability with C++ label May 16, 2023
@egorzhdan egorzhdan requested review from zoecarver and hyp as code owners May 16, 2023 11:27
@egorzhdan
Copy link
Contributor Author

@swift-ci please smoke test

@hyp
Copy link
Contributor

hyp commented May 16, 2023

Why doesn't the conformance get synthesized in C++20 mode?

@egorzhdan
Copy link
Contributor Author

Why doesn't the conformance get synthesized in C++20 mode?

I don't know, will need to investigate.

@egorzhdan egorzhdan merged commit ebcab6c into main May 16, 2023
@egorzhdan egorzhdan deleted the egorzhdan/std-vector-ubi-test branch May 16, 2023 14:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c++ interop Feature: Interoperability with C++
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants