On Sun, Feb 11, 2018 at 6:02 AM, Alexei Podtelezhnikov
<apodt...@gmail.com> wrote:
>  (void*)(size_t)(x) should be safe, c90, and warning-less.

You assume that all machines have a flat, linear memory model.... ;-(

The "safe", portable way is to use (void *)(((char *)0) + (x)) to cast
an integer to a void pointer, and use (ptrdiff_t)((char *)(x)) -
((char *)0) to cast a pointer to an integer. >

----

Bye,
Roland

-- 
  __ .  . __
 (o.\ \/ /.o) roland.ma...@nrubsig.org
  \__\/\/__/  MPEG specialist, C&&JAVA&&Sun&&Unix programmer
  /O /==\ O\  TEL +49 641 3992797
 (;O/ \/ \O;)

_______________________________________________
Freetype-devel mailing list
Freetype-devel@nongnu.org
https://lists.nongnu.org/mailman/listinfo/freetype-devel

Reply via email to