While on the subject of conduits and timing, I'm using the following
conduit to add elapsed timing information:
timedConduit :: MonadResource m => forall l o u . Pipe l o o u m (u,
NominalDiffTime)
timedConduit = bracketP getCurrentTime (\_ -> return ()) inner
where inner st = do r <- aw
Git has the ability to solve all of this.
...
2. Uploads to hackage either happen through commits to the git
repository,
or an old-style upload to hackage automatically creates a new anonymous
branch in the git repository.
3. The git repository is authorative. Signing releases, code reviews
On Wed, 01 Feb 2012 19:42:19 -0700, AntC
wrote:
A piece of background which has perhaps been implicit in the discussions
up to
now. Currently under H98:
f.g-- (both lower case, no space around the dot)
Is taken as function composition -- same as (f . g).
f. g -- is tak
fear I've mostly wasted people's time on syntactic
trivialities already well discussed and dismissed. Please do carry on, it's all
good stuff.
-KQ
Quoting AntC :
> Kevin Quick sparq.org> writes:
>
> >
> >
> > On Tue, 31 Jan 2012 23:10:34 -0700, A
On Tue, 31 Jan 2012 23:10:34 -0700, Anthony Clayden
wrote:
I'm proposing x.f is _exactly_ f x. That is, the x.f gets
desugared at an early phase in compilation.
Anthony,
I think part of the concern people are expressing here is that the above
would imply the ability to use point-free st
On Sun, 01 Jan 2012 05:29:42 -0700, Sebastian Fischer
wrote:
On Sat, Dec 31, 2011 at 4:09 PM, Kevin Quick wrote:
onVarElem :: forall a . (Show a) => (Maybe a -> String) -> Var ->
String
The problem is the scope of the quantification of the type variable 'a'.
You can
On Sat, 31 Dec 2011 08:50:05 -0700, Stephen Tetley
wrote:
Maybe you want a deconstructor (sometime called an eliminator)?
deconsVar :: (Maybe Int -> a) -> (Maybe String -> a) -> Var -> a
deconsVar f g (V1 a) = f a
deconsVar f g (V2 b) = g b
That works and has the advantage of allowing a si
I'm having some difficulty avoiding a tight parametric binding of function
parameters, which is limiting the (de)composability of my expressions.
I'm curious as to whether there is an option or method I haven't tried to
achieve this.
Here's an example test case:
data Var = V1 (Maybe Int)
On Sun, 24 Jul 2011 07:30:56 -0700, Mark Spezzano
wrote:
Hi all,
I would appreciate it if someone can point me in the right direction
with the following problem.
I'm deliberately implementing a naive Queues packages that uses finite
lists as the underlying representation. I've already
Quoting Thiago Negri :
> Hello all,
> I'm a newbie at Haskell and I was not aware of this problem.
> So, equality comparison can run into an infinite-loop?
Yes, comparing infinite lists is a non-terminating computation.
> My current knowledge of the language tells me that everything is
> Haskel
That sounds very applicable to my issue (and unfortunately my googling missed
this, ergo my consult of haskell-cafe uberwissenmensch). When I again have
access to the aforementioned Mac this evening I'll try both disabling
optimizations and a tweaked HUnit to see if that resolves the problem an
Dmitry,
I'm not directly familiar with Takusen or its use with OracleDB, but I
would hazard a guess that the withSession is doing FFI resource management
and that resources obtained inside the withSession environment are no
longer valid outside of the withSession.
If this is the case then
Quoting Antoine Latter :
> On May 25, 2011 11:08 AM, "KQ" wrote:
> >
> > The HackageDB could the provide this information in the description page
> of a package, and it could even automatically cross-reference and supplement
> the referred package descriptions, so that if you are looking at the P
On Wed, 20 Apr 2011 15:18:21 -0700, Rogan Creswick wrote:
On Wed, Apr 20, 2011 at 2:51 PM, Kevin Quick wrote:
$ cabal update
$ cabal install hakyll
Resolving dependencies...
cabal: dependencies conflict: ghc-6.12.3 requires unix ==2.4.0.2 however
unix-2.4.0.2 was excluded because ghc-6.12.3
Hmmm...
$ cabal update
$ cabal install hakyll
Resolving dependencies...
cabal: dependencies conflict: ghc-6.12.3 requires unix ==2.4.0.2 however
unix-2.4.0.2 was excluded because ghc-6.12.3 requires unix ==2.4.1.0
$
Any advice (other than upgrading to 7.0.3, which is not an option at the
moment
tput is reasonable:
$ ls -1sh *.example*
4.9M input.example
4.9M output.example1
4.9M output.example2
4.9M output.example3
4.9M output.example4
4.9M output.example5
4.9M output.example6
Hopefully this has been a useful comparison of using Iteratee
techniques in relation to more conventional monad
On Thu, 24 Feb 2011 13:45:59 -0700, Andrew Coppin
wrote:
The input list is being read from disk by lazy I/O. With the original
implementation, the input file gets read at the same time as the output file is
written. But runST returns nothing until the *entire* input has been
compressed. So
Magnus,
I used the following technique, but it was a couple of iterations of CmdArgs
ago:
data UIMode = Normal | Batch | Query deriving (Data,Typeable,Show,Eq)
uimode_arg :: forall t. t -> UIMode
uimode_arg _ = enum Normal
[ Batch &= flag "B" & text "batch mode (no interaction)
On Sun, 18 Jul 2010 12:02:39 -0700, Carter Schonwald
wrote:
nope, I was suggesting rather:
./A.hs has module A which has an import A.B line
./A/ has B.hs with module A.B which imports A.B.C
/C which has module A.B.C in file C.hs
I think this scenario should work
-carter
It's an int
On Sat, 17 Jul 2010 22:45:57 -0700, Ivan Lazar Miljenovic
wrote:
Carter Schonwald writes:
Hello All, I'm not sure if this either a bug in how ghc does path/module
lookup or it simply is invalid haskell:
consider modules A, A.B and A.B.C
where A imports A.B, and A.B imports A.B.C
with th
On Fri, 09 Jul 2010 18:57:34 -0700, Edward Kmett wrote:
I hope the above demonstrate that there are at least some fairly reasonable
(and, given your request, appropriately category theoretic!) examples where
one would want the ability to specify that there is more than one member of
a minimal mu
On Fri, 09 Jul 2010 16:26:13 -0700, Ivan Lazar Miljenovic
wrote:
"Kevin Quick" writes:
I would think that only mutually recursive default methods would
require respecification and that there could be any number of default
methods that were reasonable as is. Since it's
On Thu, 08 Jul 2010 09:48:34 -0700, Daniel Fischer
wrote:
On Thursday 08 July 2010 18:24:05, Ben Millwood wrote:
On Thu, Jul 8, 2010 at 3:45 PM, Daniel Fischer
wrote:
> Well, I made the suggestion of emitting a warning on instance
> declarations without method definitions. That would be co
On Mon, 05 Jul 2010 19:26:34 -0700, Ivan Miljenovic
wrote:
Graphviz (http://graphviz.org/) has the option to convert provided Dot
code for visualising a graph into a canonical form. For example, take
the sample Dot code:
[snip]
I've recently thought up a way that I can duplicate this functi
I started with the following:
{-# LANGUAGE TypeFamilies #-}
class DoC a where
type A2 a
op :: a -> A2 a
data Con x = InCon (x (Con x))
type FCon x = x (Con x)
foldDoC :: Functor f => (f a -> a) -> Con f -> a
foldDoC f (InCon t) = f (fmap (foldDoC f) t)
doCon :: (DoC (FCon x)) => Con
On Sat, 03 Jul 2010 13:28:44 -0700, Dan Doel wrote:
As a side note, although I agree it abuses the fundeps intent, it was handy
for the specific purpose I was implementing to have a "no-op/passthrough"
instance of op. In general I like the typedef approach better, but it
On Sat, 03 Jul 2010 12:48:56 -0700, Dan Doel wrote:
Then the instance declares infinitely many instances C Bool a a. This is a
violation of the fundep. Based on your error message, it looks like it ends up
treating the instance as the first concrete 'a' it comes across, but who
knows?
Hmmm..
On Wed, 23 Jun 2010 00:14:03 -0700, Simon Peyton-Jones
wrote:
I'm interested in situations where you think fundeps work and type families
don't. Reason: no one knows how to make fundeps work cleanly with local type
constraints (such as GADTs).
Simon,
I have run into a case where fundeps+
On Sat, 01 May 2010 15:42:09 -0700, Ivan Lazar Miljenovic
wrote:
instance Graph GrB where
-- instance (Cls a) => Graph GrB where -- error: ambiguous constraint, must
mention type a
-- instance (Cls a) => forall a. Graph GrB where -- error: malformed instance
header
-- instance (Cls a) Graph
On Sat, 01 May 2010 01:01:47 -0700, Sebastian Fischer
wrote:
On May 1, 2010, at 8:08 AM, Ivan Lazar Miljenovic wrote:
* I can't redefine the Graph methods to introduce the (Cls a)
constraint [reasonable]
Not sure if you can.
I think Kevin means that he cannot change the signature of the
On Fri, 30 Apr 2010 23:30:21 -0700, Jason Dagit wrote:
On Fri, Apr 30, 2010 at 11:08 PM, Ivan Lazar Miljenovic <
ivan.miljeno...@gmail.com> wrote:
You're putting the constraint in the wrong places: put the "(Cls a) => "
in the actual functions where you need it.
I need to use Cls methods in
I need help understanding how to express the following:
data (Cls a) => B a = B [a]
data GrB a b = GrB (B a)
instance Graph GrB where ...
In the methods for the instance specification, I need to perform Cls a
operations on a.
* As shown, the compiler complains that it cannot dedu
32 matches
Mail list logo