-
-
Notifications
You must be signed in to change notification settings - Fork 11.1k
MAINT: Simplify npymath #22090
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
MAINT: Simplify npymath #22090
Changes from 1 commit
f33e579
e9e8cee
9e481ad
aceba28
c35cb18
16a6405
c304f6f
37b2cf1
b0878cf
ee2103b
759e0cd
2c4cc10
704ca94
b6d52fc
d1cbf3f
25629dd
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
- Loading branch information
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -770,27 +770,12 @@ NumPyOS_ascii_ftoLf(FILE *fp, long double *value) | |
NPY_NO_EXPORT npy_longlong | ||
NumPyOS_strtoll(const char *str, char **endptr, int base) | ||
{ | ||
#if defined HAVE_STRTOLL | ||
return strtoll(str, endptr, base); | ||
#elif defined _MSC_VER | ||
return _strtoi64(str, endptr, base); | ||
#else | ||
/* ok on 64 bit posix */ | ||
return PyOS_strtol(str, endptr, base); | ||
#endif | ||
} | ||
|
||
NPY_NO_EXPORT npy_ulonglong | ||
NumPyOS_strtoull(const char *str, char **endptr, int base) | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Should these now more or less pointless wrapper functions be deprecated somehow...? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Agreed there is more cleanup that can be done to turn one-line functions into defines (if they are exported) or to deprecate them (if they are internal). I was primarily targeting cleaning up the dead code from npymath in this PR. Maybe we should have a github project for code cleanup and add this as a task. |
||
{ | ||
#if defined HAVE_STRTOULL | ||
return strtoull(str, endptr, base); | ||
#elif defined _MSC_VER | ||
return _strtoui64(str, endptr, base); | ||
#else | ||
/* ok on 64 bit posix */ | ||
return PyOS_strtoul(str, endptr, base); | ||
#endif | ||
} | ||
|
||
rgommers marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
Uh oh!
There was an error while loading. Please reload this page.