@@ -416,9 +416,13 @@ getInt (BI x : xs) = x : getInt xs
416416getInt _ = []
417417
418418strToInt :: IntTy -> [Const] -> Maybe Const
419−strToInt ity [Str x] = case reads x of
419+strToInt ity [Str x] = case reads $ dropFirstPlus x of
420420 [(n,s)] -> Just $ if all isSpace s then toInt ity (n :: Integer) else I 0
421421 _ -> Just $ I 0
422+ where
423+ dropFirstPlus :: String -> String
424+ dropFirstPlus ('+' : str) = str
425+ dropFirstPlus str = str
422426strToInt _ _ = Nothing
423427
424428intToFloat :: [Const] -> Maybe Const