+ | otherwise = Just (HsInline inline_prag)
+
+--------------------------
+toIfUnfolding :: Unfolding -> Maybe IfaceUnfolding
+toIfUnfolding (CoreUnfolding { uf_tmpl = rhs, uf_guidance = guidance })
+ = case guidance of
+ UnfoldNever -> Nothing
+ _ -> Just (IfCoreUnfold (toIfaceExpr rhs))
+toIfUnfolding (InlineRule { uf_worker = Just wkr, uf_arity = arity })
+ = Just (IfWrapper arity (idName wkr))
+toIfUnfolding (InlineRule { uf_worker = Nothing, uf_tmpl = rhs, uf_arity = arity })
+ = Just (IfInlineRule arity (toIfaceExpr rhs))
+toIfUnfolding _
+ = Nothing