Portability | ghc only |
---|---|
Stability | experimental |
Maintainer | Bertram Felgenhauer <int-e@gmx.de> |
Safe Haskell | Safe-Infered |
isEvaluated
allows checking for expressions that have already been
reduced to weak heaf normal form. This can be useful for racing
computations against one another; if one computation can be shown to
terminate instantly, there's no need to set up any threads for the race.
- isEvaluated :: a -> IO Bool
Documentation
isEvaluated :: a -> IO BoolSource
If isEvaluated a
returns True
, the given value is in whnf.
It may produce false negatives.