Controls the compatibility of the char* and unsigned char* types.
#pragma mpwc_relax on | off | reset
If you enable this pragma, the compiler treats char* and unsigned char* as the same type. This setting is especially useful if you are using code written before the ANSI C standard. This old source code frequently used these types interchangeably. This setting has no effect on C++ source code.
You can use this pragma to relax function pointer checking:
#pragma mpwc_relax on extern void f(char *); extern void(*fp1)(void *) = &f; // error but allowed extern void(*fp2)(unsigned char *) = &f; // error but allowed
This pragma corresponds to the Relaxed Pointer Type Rules setting in the Language panel. To check this setting, __option (mpwc_relax), described in Checking Pragma Settings. By default, this pragma is disabled.