Safe Haskell | Safe-Inferred |
---|
- applyTo :: Bool -> String -> String -> IO (String, Maybe String)
Documentation
applyTo :: Bool -> String -> String -> IO (String, Maybe String)Source
This function applies a String to String function to a certain String (everything in the context of the module Prelude).
It is expensive as it calls ghc
to produce its results. It has been
created to formally provide the mode 'apply-to' but text editors should
instead use ghc
directly. The first argument control whether a warning
message describing this fact is contained in the result. If it is False then
the second tuple element of the result will contain an according warning
otherwise it Nothing.
The result is a tuple of which the first elements contains the
(stdout-)output of the call to the ghc
and the second element may contain
warning messages. If the first function argument is False then the second
tuple element will never be Nothing. Otherwise it may be Nothing or contain
a messages (for example when the executable GHC isn'f found).