Workaround clang 10.0.1 C++17 linker errors in testcases
Fixes: Undefined symbols for architecture x86_64: "___cxa_deleted_virtual" which clang issues when a class deletes a method (seems to be when the function is not one of the compiler's automatically added special member functions).
This commit is contained in:
parent
d6ef118219
commit
06e5ab8975
2 changed files with 11 additions and 0 deletions
|
|
@ -31,8 +31,13 @@ struct NoExceptClass {
|
|||
void noo1() const noexcept {}
|
||||
static void noo2() noexcept {}
|
||||
virtual void noo3() const noexcept {}
|
||||
|
||||
// Workaround clang 10.0.1 -std=c++17 linker error (oddly for Java and not Python):
|
||||
// Undefined symbols for architecture x86_64: "___cxa_deleted_virtual", referenced from: vtable for NoExceptClass
|
||||
#if !(defined(__clang__) && __cplusplus >= 201703L)
|
||||
virtual void noo4() const noexcept = delete;
|
||||
virtual void noo5() const throw() = delete;
|
||||
#endif
|
||||
};
|
||||
|
||||
struct NoExceptAbstract {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue