mkBoringStop, mkLazyArgStop, mkRhsStop, contIsRhsOrArg,
interestingCallContext, interestingArgContext,
- interestingArg, isStrictBndr, mkArgInfo
+ interestingArg, mkArgInfo
) where
#include "HsVersions.h"
interestingArg (Type _) = False
interestingArg (App fn (Type _)) = interestingArg fn
interestingArg (Note _ a) = interestingArg a
+
+-- Idea (from Sam B); I'm not sure if it's a good idea, so commented out for now
+-- interestingArg expr | isUnLiftedType (exprType expr)
+-- -- Unlifted args are only ever interesting if we know what they are
+-- = case expr of
+-- Lit lit -> True
+-- _ -> False
+
interestingArg other = True
-- Consider let x = 3 in f x
-- The substitution will contain (x -> ContEx 3), and we want to
-- to work in Template Haskell when simplifying
-- splices, so we get simpler code for literal strings
SimplPhase n -> Just (isActive n)
-\end{code}
+\end{code}
%************************************************************************
other -> ...(case x of
0# -> ...
other -> ...) ...
-\end{code}
+\end{verbatim}
Here the inner case can be eliminated. This really only shows up in
eliminating error-checking code.