No gain, really. x will be promoted to either int or unsigned int,
and the numeric literal 0x5A, which has type int, will either be
unchanged or also promoted to unsigned int, before binary operation is
performed. Then the result will be converted back to unsigned char
for assignment back into x.
There's two things wrong with that:
1 The left operand of the assignment operator doesn't get promoted.
2 Constants of type int, are not subject to integer promotions.
N869
6.5.16.1 Simple assignment
Semantics
[#2] In simple assignment (=), the value of the right
operand is converted to the type of the assignment
expression and replaces the value stored in the object
designated by the left operand.
6.5.16 Assignment operators
Semantics
[#3]
The type of an assignment expression is
the type of the left operand unless the left operand has
qualified type, in which case it is the unqualified version
of the type of the left operand.
6.3.1.1 Boolean, characters, and integers
[#2]
If an int can represent all values of the original type, the
value is converted to an int; otherwise, it is converted to
an unsigned int. These are called the integer
promotions.