fix: using -Werror-all for Intel (#2948)

* correcting Werror for Intel

* adding ward for Intel

* adding wards for intel

* another ward for Intel

* missed one intel ward

* exact match for intel compiler

* removing inline limits

* disable warnings about inline limits

* formatter suggestion

* more indent

* hopefully make formatter happy

* addressed review

* fix &&

* Update tests/CMakeLists.txt

Co-authored-by: Henry Schreiner <HenrySchreinerIII@gmail.com>

Co-authored-by: Henry Schreiner <HenrySchreinerIII@gmail.com>
This commit is contained in:
Philipp Bucher
2021-04-14 20:01:27 +02:00
committed by GitHub
parent 6709abba93
commit 62976cfcb8
4 changed files with 18 additions and 11 deletions

View File

@@ -80,8 +80,8 @@ std::string abs(const Vector2&) {
return "abs(Vector2)";
}
// MSVC warns about unknown pragmas, and warnings are errors.
#ifndef _MSC_VER
// MSVC & Intel warns about unknown pragmas, and warnings are errors.
#if !defined(_MSC_VER) && !defined(__INTEL_COMPILER)
#pragma GCC diagnostic push
// clang 7.0.0 and Apple LLVM 10.0.1 introduce `-Wself-assign-overloaded` to
// `-Wall`, which is used here for overloading (e.g. `py::self += py::self `).
@@ -221,6 +221,6 @@ TEST_SUBMODULE(operators, m) {
.def(py::self == py::self);
}
#ifndef _MSC_VER
#if !defined(_MSC_VER) && !defined(__INTEL_COMPILER)
#pragma GCC diagnostic pop
#endif