n Tue, Mar 2, 2010 at 5:14 PM, Ivan Miljenovic
wrote:
> On 3 March 2010 08:25, Sean McLaughlin wrote:
> > For instance, if module A exports f, but A.f is never used in my compiled
> program,
> > I would like to be warned of this fact.
>
> My SourceGraph program (
> ht
Hi Don,
This doesn't tell me what is extraneous in the exports. For instance
If I have two modules A and Main
module A (f, g) where
f :: a -> a
f = id
g :: a -> a
g = id
module Main (main) where
import qualified A
main :: IO ()
main = do
let a = A.f 7
putStrLn $ show a
I'd like som
Hello,
I have a midsize program, and would like to simplify the module interfaces
for my own sanity. I know there are tools to check for extraneous imports,
but is there something similar for exports? For instance, if module A
exports f, but A.f is never used in my compiled program, I would li
Say I have the following module:
module A
( T(T)
, t
, val
)
where
data T = T { t :: Int }
val :: T
val = T 7
When I use A with the following imports, I don't expect this to work,
but it does:
import qua
Hi,
Is there a way to make haddock not generate instance documentation
for non-exported types? Right now for instance, if there is a class A
in module A, and I have a hidden type B in module B and I have
instance A.A B in module B, then in the documentation for module A,
the (supposedly hidden)
Hello,
Is there a way to get the source documentation from cabal haddock
--hyperlink-source to show up with unicode characters preserved?
Right now the unicode from my comments and source programs are being
mangled. I tried the --haddock-option="--use-unicode" option, but it
seems to only work
Hello,
I'm having trouble setting breakpoints from ghci. I load the files
and I can tell things are working correctly because I can run the
program and list the locations where I want to set breakpoints. E.g.
Prelude> :list Focus.focus
510 > focus :: forall s m. Class s m => Neg -> m [Foci]
Hi. I'm aware of this option, and use it frequently to override the
default prelude, but it doesn't help this problem:
$ ghci -XNoImplicitPrelude
GHCi, version 6.10.4: http://www.haskell.org/ghc/ :? for help
Loading package ghc-prim ... linking ... done.
Loading package integer ... linking ... d
Hello,
If there's a file called Prelude.hs in a directory, and ghci is
started from that directory, ghci dies.
-- Prelude.hs
module A.Prelude where
$ ghci
GHCi, version 6.10.4: http://www.haskell.org/ghc/ :? for help
Loading package ghc-prim ... linking ... done.
Loading package integer ... l
Hi,
I'm trying to compile some code using Cabal. One of the files has a CPP
directive
#include "undefined.h"
The file undefined.h is in the same directory as the file with the
directive.
If I use the full path name, cabal can compile it. However, if I use the
relative path,
it complains abou
Hello,
I have a program that does a lot of unicode manipulation. I'd like to use
hslogger to log various operations.
However, since hslogger uses System.IO.putX, the unicode comes out mangled.
I hacked the source to
use System.IO.UTF8 instead, but it would be nice if that was an option so I
don
Hi Daniel,
Prelude> Data.Char.isSymbol (toEnum 8704)
True
On Thu, Sep 17, 2009 at 11:09 PM, Daniel Fischer
wrote:
> Am Friday 18 September 2009 04:41:13 schrieben Sie:
> > Weird. OK, thanks a lot! I'm switching to ¥ until I get this figured
> > out. Sean
> >
>
> What does your ghci say for
>
Weird. OK, thanks a lot! I'm switching to ¥ until I get this figured out.
Sean
On Thu, Sep 17, 2009 at 10:00 PM, Daniel Fischer
wrote:
> Am Freitag 18 September 2009 03:51:40 schrieb Sean McLaughlin:
> > Hi Daniel,
> > Would you try putting that in a file and loadi
Hi Daniel,
Would you try putting that in a file and loading it in ghci? Your
example also works for me.
Prelude> let (∀) = 5
Prelude> (∀)
5
Sean
On Thu, Sep 17, 2009 at 9:41 PM, Daniel Fischer wrote:
> Am Freitag 18 September 2009 03:31:13 schrieb Sean McLaughlin:
> > Hi,
&g
Hi,
I'm getting different behavior in ghci and ghc with the identifier ∀. In
ghc I need
to wrap it with parens, as in
> (∀) :: Var -> Base -> Formula -> Formula
> (∀) = All
In ghci, I get an error this way
Formula.lhs:112:2:
Invalid type signature
In ghci I can do
> ∀ :: Var -> Base ->
Ah, I see. Thanks very much. For some reason I figured the second type would
be resolved to Int, but now I see that is totally wrong.
Best,
Sean
On Sat, Sep 12, 2009 at 8:34 PM, Brandon S. Allbery KF8NH <
allb...@ece.cmu.edu> wrote:
> On Sep 12, 2009, at 20:17 , Sean McLaugh
I'm having trouble understanding the following behavior. The following
program compiles:
{-# OPTIONS_GHC -XMultiParamTypeClasses -XFlexibleContexts #-}
import Control.Monad.State
class Has α s where
has :: s -> (α, s)
project :: (MonadState s m, Has α s) => m α
project = do (α, s) <- gets h
Hello,
I'm considering using Haskell for a numerical application. However,
I need to rely
on IEEE 754 standards being implemented correctly. What is the
current state of 754 in Haskell?
The definition has this paragraph, which makes me suspect Haskell is
not appropriate for this
application:
Hi,
To learn alex and happy, I'm trying to write a parser for a simple
expression language.
When I wrote my own lexer and just used happy, it was fine.
When I used the basic wrapper of alex it was also fine. However, when
I use the posn wrapper
to get position information, I get a strange excep
Hello,
I'm trying to write a simple function to time an application.
-- this doesn't work
time f x =
do n1 <- CPUTime.getCPUTime
let res = f x in
do n2 <- CPUTime.getCPUTime
return (res,n2 - n1)
On a function that takes 8 seconds to complete, returns
(True,4600)
A
20 matches
Mail list logo