25-06-2026, 09:03 PM
The rule 10.3 says:
What does it mean to be narrower? To have a lower rank, or to have a smaller size?
For instance, on a platform where
Is the following code compliant with rule 10.3:
My feeling is that it is compliant, because the word rank is not used here, while it is explicitly used in other parts of the rule, but I'm not 100% confident.
Quote:The value of an expression shall not be assigned to an object with a narrower //essential type//
What does it mean to be narrower? To have a lower rank, or to have a smaller size?
For instance, on a platform where
Code:
sizeof(long) == sizeof(long long)Is the following code compliant with rule 10.3:
Code:
long l = 0;
long long ll = 0;
l = ll; // Compliant or not?My feeling is that it is compliant, because the word rank is not used here, while it is explicitly used in other parts of the rule, but I'm not 100% confident.

