Hi Daniel --
that was a good lead, with a little digging around, I found
hscTcExpr :: GhcMonad m => HscEnv -> String -> m Type
which almost gets the job done, if only I could call it with
the appropriate HscEnv. The one I get using
getSession :: GhcMonad m => m HscEnv
appea
Hello,
Quick question: are safe/unsafe FFI calls interruptible?
Thanks,
Bas
___
Glasgow-haskell-users mailing list
Glasgow-haskell-users@haskell.org
http://www.haskell.org/mailman/listinfo/glasgow-haskell-users
I don't have an answer for you, but you might want to look at what :k does
in ghci, since that needs to parse a type.
On Sat, Apr 23, 2011 at 2:06 PM, Ranjit Jhala wrote:
> Hi all,
>
> can someone give me a hint as to the best way to parse a type from a
> string.
> Ideally, I'd like a function
>
Hi all,
can someone give me a hint as to the best way to parse a type from a string.
Ideally, I'd like a function
stringType :: String -> Maybe Type
or possibly,
stringType :: (GhcMonad m) => String -> m (Maybe Type)
such that,
stringType s == Just t
if in the curr