From 21f0e72b0f29cc3b631b888447454b9a21642c22 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 13 Jun 2022 21:02:25 -0400 Subject: [PATCH 1/2] [pre-commit.ci] pre-commit autoupdate (#4003) --- .pre-commit-config.yaml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index e71944875..3b4c90656 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -15,7 +15,7 @@ repos: # Standard hooks - repo: https://github.com/pre-commit/pre-commit-hooks - rev: "v4.2.0" + rev: "v4.3.0" hooks: - id: check-added-large-files - id: check-case-conflict @@ -32,7 +32,7 @@ repos: # Upgrade old Python syntax - repo: https://github.com/asottile/pyupgrade - rev: "v2.33.0" + rev: "v2.34.0" hooks: - id: pyupgrade args: [--py36-plus] @@ -123,7 +123,7 @@ repos: # Check static types with mypy - repo: https://github.com/pre-commit/mirrors-mypy - rev: "v0.960" + rev: "v0.961" hooks: - id: mypy args: [] @@ -164,7 +164,7 @@ repos: # Clang format the codebase automatically - repo: https://github.com/pre-commit/mirrors-clang-format - rev: "v14.0.3" + rev: "v14.0.4-1" hooks: - id: clang-format types_or: [c++, c, cuda] From 0964a9093a728dbf67b9b98c6371752b1a346f25 Mon Sep 17 00:00:00 2001 From: Aaron Gokaslan Date: Tue, 14 Jun 2022 14:20:26 -0400 Subject: [PATCH 2/2] Add a missing std::move in numpy.h (#4005) --- include/pybind11/numpy.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/pybind11/numpy.h b/include/pybind11/numpy.h index 43784f8e9..0291b02d0 100644 --- a/include/pybind11/numpy.h +++ b/include/pybind11/numpy.h @@ -1409,7 +1409,7 @@ PYBIND11_NOINLINE void register_structured_dtype(any_container } auto tindex = std::type_index(tinfo); - numpy_internals.registered_dtypes[tindex] = {dtype_ptr, format_str}; + numpy_internals.registered_dtypes[tindex] = {dtype_ptr, std::move(format_str)}; get_internals().direct_conversions[tindex].push_back(direct_converter); }