@@ -1655,10 +1655,7 @@ ifromJSON = iparse parseJSON
1655(.:) :: (FromJSON a) => Object -> Text -> Parser a
1655(.:) :: (FromJSON a) => Object -> Text -> Parser a
1656obj .: key = case H.lookup key obj of
1656obj .: key = case H.lookup key obj of
1657 Nothing -> fail $ "key " ++ show key ++ " not present"
1657 Nothing -> fail $ "key " ++ show key ++ " not present"
1658− Just v -> modifyFailure addKeyName
1659− $ parseJSON v <?> Key key
1658+ Just v -> parseJSON v <?> Key key
1661− addKeyName = (("failed to parse field " <> unpack key <> ": ") <>)
1662{-# INLINE (.:) #-}
1659{-# INLINE (.:) #-}
1664-- | Retrieve the value associated with the given key of an 'Object'.
1661-- | Retrieve the value associated with the given key of an 'Object'.
@@ -1671,10 +1668,7 @@ obj .: key = case H.lookup key obj of
1671(.:?) :: (FromJSON a) => Object -> Text -> Parser (Maybe a)
1668(.:?) :: (FromJSON a) => Object -> Text -> Parser (Maybe a)
1672obj .:? key = case H.lookup key obj of
1669obj .:? key = case H.lookup key obj of
1673 Nothing -> pure Nothing
1670 Nothing -> pure Nothing
1674− Just v -> modifyFailure addKeyName
1675− $ parseJSON v <?> Key key
1671+ Just v -> parseJSON v <?> Key key
1677− addKeyName = (("failed to parse field " <> unpack key <> ": ") <>)
1678{-# INLINE (.:?) #-}
1672{-# INLINE (.:?) #-}
1680-- | Like '.:?', but the resulting parser will fail,
1674-- | Like '.:?', but the resulting parser will fail,
@@ -1682,10 +1676,7 @@ obj .:? key = case H.lookup key obj of
1682(.:!) :: (FromJSON a) => Object -> Text -> Parser (Maybe a)
1676(.:!) :: (FromJSON a) => Object -> Text -> Parser (Maybe a)
1683obj .:! key = case H.lookup key obj of
1677obj .:! key = case H.lookup key obj of
1684 Nothing -> pure Nothing
1678 Nothing -> pure Nothing
1685− Just v -> modifyFailure addKeyName
1686− $ Just <$> parseJSON v <?> Key key
1679+ Just v -> Just <$> parseJSON v <?> Key key
1688− addKeyName = (("failed to parse field " <> unpack key <> ": ") <>)
1689{-# INLINE (.:!) #-}
1680{-# INLINE (.:!) #-}
1691-- | Helper for use in combination with '.:?' to provide default
1682-- | Helper for use in combination with '.:?' to provide default