It is semantically the same but does not rely on implementation- defined behavior.
@@ -115,7 +115,7 @@ static inline int rtype(Ref r)
static inline int rsval(Ref r)
{
- return (int32_t)((int64_t)r.val << 3) >> 3;
+ return ((int)r.val ^ 0x10000000) - 0x10000000;
}
enum CmpI {