Speaking of string literals, the C99 standard says (6.4.5.6):
It is unspecified whether these arrays are distinct provided their elements have the appropr
6.4.5/6 says of the arrays corresponding to string literals:
It is unspecified whether these arrays are distinct provided their elements have the appropriate values.
So that's a specific rule allowing string literals to be folded. I don't know of anything in the standard that says the same thing for other objects.