objective c - Casting between uint8_t * and char *. What happens? -


what happens when casting between these 2 in relation termination character? in c99 objective-c.

i assume char 8 bits on system in answer.

if architecture uses unsigned char char type absolutely nothing happen.

if architecture uses signed char char type negative values of char wrap around causing possibly unexpected results. never happen termination null character.


please note, "casting" nothing happens, tell compiler interpret location in memory differently. difference in interpretation create actual (side)effects of cast.


Comments

Popular posts from this blog

c# - how to write client side events functions for the combobox items -

exception - Python, pyPdf OCR error: pyPdf.utils.PdfReadError: EOF marker not found -