File tree Expand file tree Collapse file tree 2 files changed +3
-3
lines changed
stringdtype/stringdtype/src Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -48,9 +48,6 @@ typedef union _npy_static_string_u {
4848#define NPY_SHORT_STRING_MAX_SIZE \
4949 (sizeof(npy_static_string) - 1) // 15 or 7 depending on arch
5050
51- // one byte in size is reserved for flags and small string optimization
52- #define NPY_MAX_STRING_SIZE (1 << (sizeof(size_t) - 1)) - 1
53-
5451// Since this has no flags set, technically this is a heap-allocated string
5552// with size zero. Practically, that doesn't matter because we always do size
5653// checks before accessing heap data, but that may be confusing. The nice part
Original file line number Diff line number Diff line change @@ -21,6 +21,9 @@ extern const npy_packed_static_string *NPY_EMPTY_STRING;
2121// working with it.
2222extern const npy_packed_static_string * NPY_NULL_STRING ;
2323
24+ // one byte in size is reserved for flags and small string optimization
25+ #define NPY_MAX_STRING_SIZE (1 << (sizeof(size_t) - 1)) - 1
26+
2427// Allocates a new buffer for *to_init*, which must be set to NULL before
2528// calling this function, filling the newly allocated buffer with the copied
2629// contents of the first *size* entries in *init*, which must be valid and
You can’t perform that action at this time.
0 commit comments