[Haskell-cafe] about import alias

Neil Mitchell ndmitchell at gmail.com
Sat Apr 4 12:13:48 EDT 2009


Hi

> You can always do
>
> {-# INLINE short #-}
> short =
> C.veryLongFunctionNameThatIReallyDoNotWantToTypeOutEveryTimeIUseIt

The INLINE pragma is not necessary, if an optimising compiler fails to
inline that then it's not very good.

However, you might want to consider the (evil) monomorphism
restriction which will make that pattern fail for any functions with
type classes.

Thanks

Neil


More information about the Haskell-Cafe mailing list