On Mon, 2005-09-26 at 10:36 +0200, Gracjan Polak wrote:
> Simon Peyton-Jones wrote:
> > Hmm. Q is a monad, so I think
> > fail :: Monad m => String -> m a
> > will do the job.
> >
> > 'recover' should catch the exception, and let you try something else.
>
> So I think I have bug report :)
>
I go now with my
failing test cases?
--
Gracjan
Simon
| -Original Message-
| From: Gracjan Polak [mailto:[EMAIL PROTECTED]
| Sent: 20 September 2005 10:43
| To: Simon Peyton-Jones
| Cc: haskell-cafe@haskell.org
| Subject: Re: [Haskell-cafe] Template Haskell and Types
|
| Simon Pe
To: Simon Peyton-Jones
| Cc: haskell-cafe@haskell.org
| Subject: Re: [Haskell-cafe] Template Haskell and Types
|
| Simon Peyton-Jones wrote:
| > design note http://research.microsoft.com/~simonpj/tmp/notes2.ps
|
|
| In the above paper there is something about 'giveUp'. Seems to quite
|
Simon Peyton-Jones wrote:
design note http://research.microsoft.com/~simonpj/tmp/notes2.ps
In the above paper there is something about 'giveUp'. Seems to quite
useful, but there is no such thing in ghc 6.4.
Where did my giveUp go? And why?
--
Gracjan
___
Simon Peyton-Jones wrote:
| > putStrLn $(mysplice ''MyData)
| >
|
| Thanks for responses. Is there any up-to-date documentation avaliable?
Template Haskell is, alas, poorly documented. I would really welcome
someone to volunteer to help write better documentation. Meanwhile, as
the user
On Tuesday 13 September 2005 09:16, Gracjan Polak wrote:
> Tomasz Zielonka wrote:
> > On Mon, Sep 12, 2005 at 12:08:14PM +0200, Gracjan Polak wrote:
> >>Probably very simple question about template haskell: How do I make
> >> a type for an argument to splice? Example:
> >>
> >>data MyData = MyData1
| > putStrLn $(mysplice ''MyData)
| >
|
| Thanks for responses. Is there any up-to-date documentation avaliable?
Template Haskell is, alas, poorly documented. I would really welcome
someone to volunteer to help write better documentation. Meanwhile, as
the user manual says, the stuff about
Tomasz Zielonka wrote:
On Mon, Sep 12, 2005 at 12:08:14PM +0200, Gracjan Polak wrote:
Probably very simple question about template haskell: How do I make a
type for an argument to splice? Example:
data MyData = MyData1 | MyData2
mysplice mytype =
[| litE $ stringL $ show mytype |]
main =
On Mon, Sep 12, 2005 at 12:08:14PM +0200, Gracjan Polak wrote:
>
> Probably very simple question about template haskell: How do I make a
> type for an argument to splice? Example:
>
> data MyData = MyData1 | MyData2
>
> mysplice mytype =
>[| litE $ stringL $ show mytype |]
>
> main = do
>
I'm not exactly sure what it is that you're trying to do with that
code, but here's an approximation to that code which prints the
Template Haskell representation of the type MyData:
import Language.Haskell.TH
import Monad
data MyData = MyData1 | MyData2
main = do putStrLn $(liftM (LitE . string
10 matches
Mail list logo