diff options
author | nulano <nulano@nulano.eu> | 2020-08-17 21:45:19 +0200 |
---|---|---|
committer | nulano <nulano@nulano.eu> | 2020-08-17 21:45:19 +0200 |
commit | 11b4b285adb91168e5b19e1236031b081fc1e200 (patch) | |
tree | 838b6c3f124d8ad31ef61238e25d7fc2603f8d15 /rpython/translator/c | |
parent | change some longs to Signeds in c sources; these should not matter, but avoid... (diff) | |
download | pypy-11b4b285adb91168e5b19e1236031b081fc1e200.tar.gz pypy-11b4b285adb91168e5b19e1236031b081fc1e200.tar.bz2 pypy-11b4b285adb91168e5b19e1236031b081fc1e200.zip |
fix long vs Signed error in stacklet.c
Diffstat (limited to 'rpython/translator/c')
-rw-r--r-- | rpython/translator/c/src/stacklet/stacklet.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/rpython/translator/c/src/stacklet/stacklet.c b/rpython/translator/c/src/stacklet/stacklet.c index 5b88964121..eed2fb7de3 100644 --- a/rpython/translator/c/src/stacklet/stacklet.c +++ b/rpython/translator/c/src/stacklet/stacklet.c @@ -353,23 +353,23 @@ void stacklet_destroy(stacklet_handle target) char **_stacklet_translate_pointer(stacklet_handle context, char **ptr) { char *p = (char *)ptr; - long delta; + Signed delta; if (context == NULL) return ptr; check_valid(context); delta = p - context->stack_start; - if (((unsigned long)delta) < ((unsigned long)context->stack_saved)) { + if (((Unsigned)delta) < ((Unsigned)context->stack_saved)) { /* a pointer to a saved away word */ char *c = (char *)(context + 1); return (char **)(c + delta); } - if (((unsigned long)delta) >= - (unsigned long)(context->stack_stop - context->stack_start)) { + if (((Unsigned)delta) >= + (Unsigned)(context->stack_stop - context->stack_start)) { /* out-of-stack pointer! it's only ok if we are the main stacklet and we are reading past the end, because the main stacklet's stack stop is not exactly known. */ _check(delta >= 0); - _check(((long)context->stack_stop) & 1); + _check(((Signed)context->stack_stop) & 1); } return ptr; } |