On 10/17/09, Andrew Coppin wrote:
> Derek Elkins wrote:
>> See vacuum: http://hackage.haskell.org/package/vacuum
>>
> Could be useful... Thanks!
>
As Derek mentioned, vacuum would be perfect for this:
-
import Data.Wo
Derek Elkins wrote:
See vacuum: http://hackage.haskell.org/package/vacuum
Could be useful... Thanks!
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe
See vacuum: http://hackage.haskell.org/package/vacuum
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe
No problem, just trying to make sure the conversation stays on track :-)
-Ross
On Oct 16, 2009, at 3:26 PM, Daniel Peebles wrote:
Whoops, sorry about that then!
On Fri, Oct 16, 2009 at 2:59 PM, Ross Mellgren hask...@z.odi.ac> wrote:
Andrew has mentioned the debugger several times, NOT the
i
Whoops, sorry about that then!
On Fri, Oct 16, 2009 at 2:59 PM, Ross Mellgren wrote:
> Andrew has mentioned the debugger several times, NOT the interactive REPL.
> That is, using :-commands to inspect values.
>
> -Ross
>
> On Oct 16, 2009, at 2:46 PM, Daniel Peebles wrote:
>
>> My GHCi can't do t
yep
add Show to your abstrac container. , for example:
data SDynamic= forall a.Show a => SDynamic a
instance Show SDynamic where
show (SDynamic a)= show a
2009/10/16 David Virebayre
>
On Fri, Oct 16, 2009 at 8:19 PM, Andrew Coppin
> wrote:
> > Is there any way that you can turn an arbi
Andrew has mentioned the debugger several times, NOT the interactive
REPL. That is, using :-commands to inspect values.
-Ross
On Oct 16, 2009, at 2:46 PM, Daniel Peebles wrote:
My GHCi can't do that :o
I just wrote data A = B | C and loaded the file into GHCi. Typing B
gives me:
:1:0:
My GHCi can't do that :o
I just wrote data A = B | C and loaded the file into GHCi. Typing B gives me:
:1:0:
No instance for (Show A)
arising from a use of `print' at :1:0
Possible fix: add an instance declaration for (Show A)
In a stmt of a 'do' expression: print it
The error
Jochem Berndsen wrote:
I rephrase: There *is* a way to turn arbitrary values into strings. I
know there is, because the GHCi debugger *does* it. The question is,
does anybody know of an /easy/ way to do this?
No. GHCi does not always do this:
Prelude Data.Ratio> let plus1 = (+1)
Prelude
Hello Andrew,
Friday, October 16, 2009, 10:19:46 PM, you wrote:
> actually print out what's in it. On the other hand, I don't want to
> alter the entire program to have Show constraints everywhere just so I
> can print out some debug traces (and then alter everything back again
> afterwards once
Andrew Coppin wrote:
> Is there any way that you can turn an arbitrary Haskell value into a
> string?
No, the only values of type
a -> String
are the constant functions and _|_.
> I rephrase: There *is* a way to turn arbitrary values into strings. I
> know there is, because the GHCi debugger *doe
GHCi can't show you functions can it? Unless you have a Show instance
for functions loaded. I think the basic answer is no, not even with
crazy unsafe stuff, because without the typeclass constraint GHC
doesn't know to pass around the secret dictionary containing the
methods that tell it how to sho
David Virebayre wrote:
On Fri, Oct 16, 2009 at 8:19 PM, Andrew Coppin
wrote:
Is there any way that you can turn an arbitrary Haskell value into a string?
I rephrase: There *is* a way to turn arbitrary values into strings. I know
there is, because the GHCi debugger *does* it. The q
On Fri, Oct 16, 2009 at 8:19 PM, Andrew Coppin
wrote:
> Is there any way that you can turn an arbitrary Haskell value into a string?
> I rephrase: There *is* a way to turn arbitrary values into strings. I know
> there is, because the GHCi debugger *does* it. The question is, does anybody
> know o
Is there any way that you can turn an arbitrary Haskell value into a string?
I rephrase: There *is* a way to turn arbitrary values into strings. I
know there is, because the GHCi debugger *does* it. The question is,
does anybody know of an /easy/ way to do this?
Basically, I'm writing a mutab
15 matches
Mail list logo