[Git][cmucl/cmucl][master] Fix compiler warning

Raymond Toy rtoy at common-lisp.net
Sun Aug 5 23:47:39 UTC 2018


Raymond Toy pushed to branch master at cmucl / cmucl


Commits:
2de12cd7 by Raymond Toy at 2018-08-05T23:46:44Z
Fix compiler warning

clang complains:

 warning: incompatible pointer to integer conversion passing
      'lispobj *' (aka 'unsigned long *') to parameter of type 'lispobj' (aka 'unsigned long');
      dereference with * [-Wint-conversion]
        || in_range_p(addr, control_stack, control_stack_size)

So cast control_stack to lispobj.  Same complaint for binding_stack
too.

- - - - -


1 changed file:

- src/lisp/Linux-os.c


Changes:

=====================================
src/lisp/Linux-os.c
=====================================
--- a/src/lisp/Linux-os.c
+++ b/src/lisp/Linux-os.c
@@ -385,8 +385,8 @@ valid_addr(os_vm_address_t addr)
 	|| in_range_p(addr, STATIC_SPACE_START, static_space_size)
 	|| in_range_p(addr, DYNAMIC_0_SPACE_START, dynamic_space_size)
 	|| in_range_p(addr, DYNAMIC_1_SPACE_START, dynamic_space_size)
-	|| in_range_p(addr, control_stack, control_stack_size)
-	|| in_range_p(addr, binding_stack, binding_stack_size))
+	|| in_range_p(addr, (lispobj) control_stack, control_stack_size)
+	|| in_range_p(addr, (lispobj) binding_stack, binding_stack_size))
 	return TRUE;
     return FALSE;
 }



View it on GitLab: https://gitlab.common-lisp.net/cmucl/cmucl/commit/2de12cd70652794979529cdfc9da637e5164a89c

-- 
View it on GitLab: https://gitlab.common-lisp.net/cmucl/cmucl/commit/2de12cd70652794979529cdfc9da637e5164a89c
You're receiving this email because of your account on gitlab.common-lisp.net.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mailman.common-lisp.net/pipermail/cmucl-cvs/attachments/20180805/c6b3b6d0/attachment.html>


More information about the cmucl-cvs mailing list