Skip to content

Commit

Permalink
Fix: didn't use unsigned cast
Browse files Browse the repository at this point in the history
  • Loading branch information
fangerer committed Dec 29, 2022
1 parent 4066250 commit 4efcdf3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion hpy/devel/include/hpy/cpython/misc.h
Original file line number Diff line number Diff line change
Expand Up @@ -439,7 +439,7 @@ HPyAPI_FUNC HPy HPyLong_FromInt32_t(HPyContext *ctx, int32_t value) {

HPyAPI_FUNC HPy HPyLong_FromUInt32_t(HPyContext *ctx, uint32_t value) {
#if SIZEOF_LONG >= SIZEOF_INT32
return _py2h(PyLong_FromLong((long)value));
return _py2h(PyLong_FromLong((unsigned long)value));
#else
return ctx_Long_FromUInt32_t ( ctx, value );
#endif
Expand Down

0 comments on commit 4efcdf3

Please sign in to comment.