Skip to content

Commit 9a90783

Browse files
committed
Merge branch 'master' into sh_merge_master
2 parents 7087a74 + a19daea commit 9a90783

File tree

4 files changed

+11
-5
lines changed

4 files changed

+11
-5
lines changed

include/pybind11/eigen/matrix.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,9 @@
1919
PYBIND11_WARNING_PUSH
2020
PYBIND11_WARNING_DISABLE_MSVC(5054) // https://github.com/pybind/pybind11/pull/3741
2121
// C5054: operator '&': deprecated between enumerations of different types
22+
#if defined(__MINGW32__)
2223
PYBIND11_WARNING_DISABLE_GCC("-Wmaybe-uninitialized")
24+
#endif
2325

2426
#include <Eigen/Core>
2527
#include <Eigen/SparseCore>

include/pybind11/eigen/tensor.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,9 @@ static_assert(__GNUC__ > 5, "Eigen Tensor support in pybind11 requires GCC > 5.0
1717
PYBIND11_WARNING_PUSH
1818
PYBIND11_WARNING_DISABLE_MSVC(4554)
1919
PYBIND11_WARNING_DISABLE_MSVC(4127)
20+
#if defined(__MINGW32__)
2021
PYBIND11_WARNING_DISABLE_GCC("-Wmaybe-uninitialized")
22+
#endif
2123

2224
#include <unsupported/Eigen/CXX11/Tensor>
2325

include/pybind11/numpy.h

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1121,10 +1121,10 @@ class array_t : public array {
11211121

11221122
/**
11231123
* Returns a proxy object that provides const access to the array's data without bounds or
1124-
* dimensionality checking. Unlike `unchecked()`, this does not require that the underlying
1125-
* array have the `writable` flag. Use with care: the array must not be destroyed or reshaped
1126-
* for the duration of the returned object, and the caller must take care not to access invalid
1127-
* dimensions or dimension indices.
1124+
* dimensionality checking. Unlike `mutable_unchecked()`, this does not require that the
1125+
* underlying array have the `writable` flag. Use with care: the array must not be destroyed
1126+
* or reshaped for the duration of the returned object, and the caller must take care not to
1127+
* access invalid dimensions or dimension indices.
11281128
*/
11291129
template <ssize_t Dims = -1>
11301130
detail::unchecked_reference<T, Dims> unchecked() const & {

pybind11/setup_helpers.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -174,7 +174,9 @@ def cxx_std(self) -> int:
174174
@cxx_std.setter
175175
def cxx_std(self, level: int) -> None:
176176
if self._cxx_level:
177-
warnings.warn("You cannot safely change the cxx_level after setting it!")
177+
warnings.warn(
178+
"You cannot safely change the cxx_level after setting it!", stacklevel=2
179+
)
178180

179181
# MSVC 2015 Update 3 and later only have 14 (and later 17) modes, so
180182
# force a valid flag here.

0 commit comments

Comments
 (0)