Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
gaoqiong
pybind11
Commits
978617f6
Unverified
Commit
978617f6
authored
Jan 31, 2022
by
Aaron Gokaslan
Committed by
GitHub
Jan 31, 2022
Browse files
fix issue 3668 by removing bool casts in numpy.h (#3669)
parent
3a8d9230
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
include/pybind11/numpy.h
include/pybind11/numpy.h
+2
-2
No files found.
include/pybind11/numpy.h
View file @
978617f6
...
@@ -170,10 +170,10 @@ struct npy_api {
...
@@ -170,10 +170,10 @@ struct npy_api {
}
}
bool
PyArray_Check_
(
PyObject
*
obj
)
const
{
bool
PyArray_Check_
(
PyObject
*
obj
)
const
{
return
(
bool
)
PyObject_TypeCheck
(
obj
,
PyArray_Type_
);
return
PyObject_TypeCheck
(
obj
,
PyArray_Type_
)
!=
0
;
}
}
bool
PyArrayDescr_Check_
(
PyObject
*
obj
)
const
{
bool
PyArrayDescr_Check_
(
PyObject
*
obj
)
const
{
return
(
bool
)
PyObject_TypeCheck
(
obj
,
PyArrayDescr_Type_
);
return
PyObject_TypeCheck
(
obj
,
PyArrayDescr_Type_
)
!=
0
;
}
}
unsigned
int
(
*
PyArray_GetNDArrayCFeatureVersion_
)();
unsigned
int
(
*
PyArray_GetNDArrayCFeatureVersion_
)();
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment