I've pushed the discussed changes to the repo[1], it'd be good if you
(and other users) could test them before they get to hackage.
[1] darcs get http://patch-tag.com/r/Saizan/syb-with-class/
-- Andrea
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell
On Mon, Sep 3, 2012 at 2:53 PM, Roman Cheplyaka wrote:
> * Andrea Vezzosi [2012-09-03 12:50:03+0200]
>> > [...]
>>
>> This is pretty similar to what ended up being a ghc bug, fixed in 7.0 though:
>> http://hackage.haskell.org/trac/ghc/ticket/3731
>
> The dif
Data ctx Foo where ...
>
> What's the proper way to fix it?
>From a few tests it seems we no longer need the circular context hack
in ghc-7.4.1 to get the instance to typecheck, so we could side-step
the issue entirely by removing it from the generated code.
-- Andrea Vezzosi
_
On Sun, Jan 9, 2011 at 7:45 AM, Sebastian Fischer wrote:
> [...]
> Only conversion to the underlying Set type requires an Ord constraint.
> getSet :: Ord a => Set a -> S.Set a
> getSet a = a >>- S.singleton
this unfortunately also means that duplicated elements only get
filtered out at th
On Thu, May 13, 2010 at 8:13 PM, wren ng thornton wrote:
> Andrea Vezzosi wrote:
>>
>> On Thu, May 13, 2010 at 10:51 AM, wren ng thornton
>> wrote:
>>>
>>> Andrea Vezzosi wrote:
>>>>
>>>> wren ng thornton wrote:
>>
On Thu, May 13, 2010 at 10:51 AM, wren ng thornton wrote:
> Andrea Vezzosi wrote:
>>
>> wren ng thornton wrote:
>>>
>>> With this change [1] I can't notice any difference for your benchmark[2].
>>> Then again, all the runTest calls take 0 msec and I
On Wed, May 12, 2010 at 7:50 AM, wren ng thornton wrote:
> wren ng thornton wrote:
>>
>> Here's one big difference:
>>
newtype ErrCPS e m a = ErrCPS { runErrCPS ::
forall r . (e -> m r) -- error handler
-> (a -> m r) -- success handler
-> m r }
>>
>> The analogous ve
On Mon, Dec 7, 2009 at 3:38 PM, David Fox wrote:
> On Sat, Dec 5, 2009 at 2:38 AM, Andrea Vezzosi wrote:
>> On Fri, Dec 4, 2009 at 8:51 PM, Jeremy Shaw wrote:
>>> I have stripped things down to the bare minimum, and test under GHC 6.10,
>>> GHC 6.12, Linux, and Mac O
On Fri, Dec 4, 2009 at 8:51 PM, Jeremy Shaw wrote:
> I have stripped things down to the bare minimum, and test under GHC 6.10,
> GHC 6.12, Linux, and Mac OS X. Results are consistent.
>
> In the following code,
>
> 1. if you load the code into ghci and evaluate e it will hang, but
> (defaultValue
The main bottleneck right now is that each ghc process has to read the
package.conf, which afaiu is done with Read and it's awfully slow,
especially if you have many packages installed.
I've started seeing total time improvements when approaching ~300% CPU
usage and only the extralibs installed.
O
Which version of Cabal are you using?
It should be fixed with Cabal-1.6.0.2, check cabal --version to make
sure it's not using an older one.
On Mon, Apr 6, 2009 at 8:32 PM, Martijn van Steenbergen
wrote:
> Hello,
>
> cabal generates a Paths_Xxx file for me which I import and use, but cabal
> hadd
I should clarify that cabal install --global won't see the packages
installed in the user db, even if not run as root.
But it at least will take into consideration the available packages'
cache and the config file in ~/.cabal/
___
Haskell-Cafe mailing lis
On Sun, Mar 22, 2009 at 12:51 PM, Colin Paul Adams
wrote:
>> "Achim" == Achim Schneider writes:
>
> Achim> Colin Paul Adams wrote:
> >> So why doesn't it find packages then, when they are installed?
> >>
> Achim> I've got no idea, what exactly are you trying to do, and
> Achim
2009/3/6 Daryoush Mehrtash :
> Two questions:
>
> a) This chat server implementation doesn't actually close the connection
> as a real one would need to do. If you use "forever" is there a way to end
> the loop so as to end the connection?
Yes, throw an exception and catch it from outside the
2009/2/22 Luke Palmer :
> On Sun, Feb 22, 2009 at 8:15 AM, John Meacham wrote:
>>
>> On Sun, Feb 22, 2009 at 03:36:34PM +0100, Peter Verswyvelen wrote:
>> > Would it be possible to separate the frontend (Haskell to Core) and
>> > backend
>> > (Core to machine code) from the Haskell compilers (requ
the solution here is to compile Setup.hs with ghc first, i.e. "ghc
--make Setup.hs" and then use the produced Setup.exe, this is also
recommended un linux since runghc will have to load and interpret many
modules if not.
However if you've already built cabal-install against 1.6.0.1 you can
simply
On Tue, Feb 17, 2009 at 11:50 PM, Achim Schneider wrote:
> Martin Huschenbett wrote:
>
>> $ cabal install ghci-haskeline
>> Resolving dependencies...
>> cabal.exe: dependencies conflict: ghc-6.10.1 requires process
>> ==1.0.1.1 however
>> process-1.0.1.1 was excluded because ghc-6.10.1 requires p
d when using Haddock 2, but if it is, it would solve this
>> problem.
>
> Yes, against my better judgement the code in Cabal for haddock-2.x does
> not run cpp or unliting like it does for haddock-0.x. Instead it assumes
> that haddock-2.x will do all the cpp and unliting itself. Obvi
Does it also let you apply a suggestion automatically?
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe
On Thu, Jan 8, 2009 at 5:25 AM, wren ng thornton wrote:
>
> The question for y'all is what should I call it? I've been calling the
> template-function qaf (for Compiled Applicative Form ;) and the type class
> with that function would be the only thing in the package, but I'm not sure
> where Q
Tried running the program with +RTS -Nn where n = 2 or more? that should use
more OS threads
On Sun, Dec 21, 2008 at 10:43 PM, Günther Schmidt wrote:
> Hi,
>
> in an application of mine I start a long-running operation in a thread via
> forkIO so that the UI process doesn't get blocked.
> It jus
If you want to defer the choice of 's' you've to make it appear in the type
signature of test1, so you've to introduce an artificial parameter even if
we're interested only in its type. e.g.:
data Proxy (s :: * -> * -> *) -- useful because we can't have an argument
of type 's' directly, since it's
On Mon, Nov 24, 2008 at 7:40 AM, Andrea Vezzosi <[EMAIL PROTECTED]> wrote:
> It's more natural to consider the cross product of no sets to be [[]] so
> your crossr becomes:
>
> crossr [] = [[]]
> crossr (x:xs) = concat (map (\h ->map (\t -> h:t) (crossr tail)) h
It's more natural to consider the cross product of no sets to be [[]] so
your crossr becomes:
crossr [] = [[]]
crossr (x:xs) = concat (map (\h ->map (\t -> h:t) (crossr tail)) hd)
which we can rewrite with list comprehensions for conciseness:
crossr [] = [[]]
crossr (x:xs) = [ a:as | a <- x, a
I'd rather say that STM is intended to be used just for building up
transactions, not to model your whole process/thread, simply because in the
latter case your process couldn't have any observable intermediate state, or
put in another way, between any two transactions the information can only go
i
2008/10/9 Claus Reinke <[EMAIL PROTECTED]>
> I was wondering if it was possible to implement synchronous channels
>> within STM. In particular, I'd like to have CSP-like send and recv
>> primitives
>> on a channel that each block until the other side arrives to complete
>> the transaction.
>>
>
>
As i understand it, the monomorphism restriction applies to "constrained
type variables", but c :: forall a. a, so it remains polymorphic and each of
its uses can be instantiated to a different type.
2007/12/25, Henning Thielemann <[EMAIL PROTECTED]>:
>
>
> I thought I understand monomorphism rest
As a side note i'd like to point out that introspectData has a problem with
constructors containing Strings because show (x::String) /= x:
data Foo = Foo { bar :: String } deriving (Typeable,Data)
introspectData (Foo "quux") --> [("bar","\"quux\"")]
Those extras \" don't look very nice in the x
if by "figure out" you meant to "do what tell does without using it", you
should have written:
foo = Writer ((),"hello")
that would have had the right type, using return you are doing something
different.
in the Writer monad return :: Monoid w => a -> Writer w a
so return ((),"hello") :: Monoid w
29 matches
Mail list logo