diff --git a/src/frontc/cabs2cil.ml b/src/frontc/cabs2cil.ml index 1f0c524ad..b4366dbb6 100644 --- a/src/frontc/cabs2cil.ml +++ b/src/frontc/cabs2cil.ml @@ -4009,12 +4009,7 @@ and doExp (asconst: bool) (* This expression is used as a constant *) let (se, e', t) = doExp asconst e (AExp None) in if isIntegralType t then let tres = integralPromotion t in - let fallback = UnOp(Neg, makeCastT ~kind:IntegerPromotion ~e:e' ~oldt:t ~newt:tres, tres) in - let e'' = - match e', tres with - | Const(CInt(i, _, _)), TInt(ik, _) -> const_if_not_overflow fallback ik (neg_cilint i) - | _ -> fallback - in + let e'' = UnOp(Neg, makeCastT ~kind:IntegerPromotion ~e:e' ~oldt:t ~newt:tres, tres) in finishExp se e'' tres else if isArithmeticType t then