summaryrefslogtreecommitdiff
path: root/numpy/core
diff options
context:
space:
mode:
authorSebastian Berg <sebastian@sipsolutions.net>2023-04-27 11:58:56 +0200
committerGitHub <noreply@github.com>2023-04-27 11:58:56 +0200
commit0dc83e270a7891ad27e38bb94d8567deaff5df51 (patch)
tree6561a10e6464664b26d85486153c275b82be87e3 /numpy/core
parent569f7bc692aab41014ddc683c06e84e1bc276305 (diff)
downloadnumpy-0dc83e270a7891ad27e38bb94d8567deaff5df51.tar.gz
Apply suggestions from code review
Co-authored-by: Matti Picus <matti.picus@gmail.com>
Diffstat (limited to 'numpy/core')
-rw-r--r--numpy/core/src/multiarray/usertypes.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/numpy/core/src/multiarray/usertypes.c b/numpy/core/src/multiarray/usertypes.c
index 4f5b05eb6..16ca74ef8 100644
--- a/numpy/core/src/multiarray/usertypes.c
+++ b/numpy/core/src/multiarray/usertypes.c
@@ -263,7 +263,7 @@ PyArray_RegisterDataType(PyArray_Descr *descr)
/*
* Legacy user DTypes classes cannot have a name, since the user never
- * defined on. So we create a name for them here, these DTypes are
+ * defined one. So we create a name for them here. These DTypes are
* effectively static types.
*
* Note: we have no intention of freeing the memory again since this
@@ -297,7 +297,7 @@ PyArray_RegisterDataType(PyArray_Descr *descr)
if (dtypemeta_wrap_legacy_descriptor(descr, name, NULL) < 0) {
descr->type_num = -1;
NPY_NUMUSERTYPES--;
- PyMem_Free(name); /* free the name on failure, but only then */
+ PyMem_Free(name); /* free the name only on failure */
return -1;
}
if (use_void_clearimpl) {