What is the deal with assigning an unsigned variable to a signed value?
问题 This code I am looking at has a lot of places where I see things like this happening: char *functionName(char *passedVariable) { unsigned char *newVariable = (char* ) passedVariable; Why is this being done? I always try to be consistent in the use of signed/unsigned, because I know that switching between the two can cause problems, but this developer doesn't seem to care. 回答1: Changing the pointer type is not really an issue, this address will still be valid. However interpreting the pointed