Commit Graph

7 Commits

Author SHA1 Message Date
Saleem Abdulrasool
df9d1e815f Interop/Cxx: explicitly require C++ for modules
The C++ interop modules require C++ support.  Explicitly require C++ as
a feature when building these modules.  This has no impact on the
changes as all the tests enable C++ already.
2021-01-06 16:59:42 -08:00
Michael Forster
d530e36236 Add tests for C++ out-of-line member operators (#32718) 2020-07-07 19:26:23 +02:00
Michael Forster
26358c4588 Import member operator functions as static members (#32293)
This adds support to `ClangImporter` to import C++ member function operators as static methods into Swift, which is part of SR-12748.

The left-hand-side operand, which gets passed as the `this` pointer to the C++ function is represented as an additional first parameter in the Swift method. It gets mapped back in SILGen.

Two of the tests are disabled on Windows because we can't yet call member functions correctly on Windows (SR-13129).
2020-07-03 11:06:22 +02:00
Michael Forster
0838a65e0d Test C++ out-of-line operator functions
Add a test to verify that C++ out-of-line operator functions are imported correctly.
Includes fixes for armv7 and arm64.

This is part of addressing SR-12748.
2020-06-05 12:32:23 +02:00
Michael Forster
e5e34fa3c9 Revert "Test C++ out-of-line operator functions (#32081)" (#32181)
This reverts commit f7473a7432.
2020-06-04 19:10:04 +02:00
Michael Forster
f7473a7432 Test C++ out-of-line operator functions (#32081)
Add tests to verify that C++ out-of-line operator functions are
imported correctly.
2020-06-03 10:37:27 +02:00
Michael Forster
c98c862e7e Start implementing C++ operator interop (#32015)
This imports the four basic arithmetic operators `+`, `-`, `*`, `/`
declared as inline non-member functions.

More to come.
2020-05-28 17:31:36 +02:00