Pointer Arithmetic & Signed / Unsigned Conversions!
Posted
by Jay
on Stack Overflow
See other posts from Stack Overflow
or by Jay
Published on 2010-04-05T12:54:19Z
Indexed on
2010/04/05
13:03 UTC
Read the original article
Hit count: 322
c
|pointer-arithmetic
Incase of pointer arithmetic, are the integers automatically converted to their signed variants? If yes, why?
Suppose I do
pointer + uiVal
where pointer is a pointer to int and uiVal is initialized to -1, then I find that the address in pointers get decremented by 4. Why is the unsigned value of -1 not considered here?
© Stack Overflow or respective owner