-
Notifications
You must be signed in to change notification settings - Fork 51
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
f4df662
commit 2094c7c
Showing
2 changed files
with
32 additions
and
0 deletions.
There are no files selected for viewing
31 changes: 31 additions & 0 deletions
31
recipes/recipes_emscripten/matplotlib/patches/static-cast.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
From 1b919a42a6be3090d4553cafff8f0c0f9e221d60 Mon Sep 17 00:00:00 2001 | ||
From: Ian Thomas <ianthomas23@gmail.com> | ||
Date: Tue, 14 Jan 2025 14:34:34 +0000 | ||
Subject: [PATCH] Static cast patch | ||
|
||
--- | ||
src/_backend_agg_wrapper.cpp | 6 +++--- | ||
1 file changed, 3 insertions(+), 3 deletions(-) | ||
|
||
diff --git a/src/_backend_agg_wrapper.cpp b/src/_backend_agg_wrapper.cpp | ||
index 269e2aaa9e..2bad7f4d0b 100644 | ||
--- a/src/_backend_agg_wrapper.cpp | ||
+++ b/src/_backend_agg_wrapper.cpp | ||
@@ -250,12 +250,12 @@ PYBIND11_MODULE(_backend_agg, m, py::mod_gil_not_used()) | ||
|
||
.def_buffer([](RendererAgg *renderer) -> py::buffer_info { | ||
std::vector<py::ssize_t> shape { | ||
- renderer->get_height(), | ||
- renderer->get_width(), | ||
+ static_cast<py::ssize_t>(renderer->get_height()), | ||
+ static_cast<py::ssize_t>(renderer->get_width()), | ||
4 | ||
}; | ||
std::vector<py::ssize_t> strides { | ||
- renderer->get_width() * 4, | ||
+ static_cast<py::ssize_t>(renderer->get_width() * 4), | ||
4, | ||
1 | ||
}; | ||
-- | ||
2.39.3 (Apple Git-146) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters