Re: [Haskell-cafe] [haskell.org Google Summer of Code 2013] Approved Projects

2013-05-29 Thread harry
Edward Kmett ekmett at gmail.com writes:

 * Haskell Qt Binding Generator by Zhengliang Feng, mentored by Carter
Schonwald with help from Ian-Woo Kim

Interesting, as this has been done at least twice before. Is there a public
write-up of what's going to be different this time?


___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Install wx on Windows XP

2013-05-29 Thread harry
On Tue, 26 Mar 2013 08:58:18 +0100, Eric Wong wsysdu at gmail.com wrote:

 The best way to do this, is to download from
https://github.com/atzedijkstra/wxHaskell
 . (This is the most up to date repository online.) Then replace the  
 wxcore\Setup.hs file with the one attached to this e-mail (this has not  
 been tested on non-Windows platforms). Install all wxHaskell packages from  
 this repository, in the following order:
wxdirect
wxc
wxcore
wx

I tried that on the latest HP, and it insisted on downloading the old
version of wxdirect to sovle some dependency in wxcore, then rebuild wxc
against it, and got back to the old problems.

Is there going to be a new release on hackage with the fixes?


___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] [haskell.org Google Summer of Code 2013] Approved Projects

2013-05-29 Thread harry
Edward Kmett ekmett at gmail.com writes:

 There should be a link from the google-melange website, but one slight
shift in focus is on either getting SWIG bindings or possibly even using
Ian-Woo Kim's C++FFI tools. Carter may be able to go into more detail.

There's almost no information in the google project abstract. My concern is
that the problem isn't generating the bindings (as I've said, that's been
done twice before). It's that Qt's slots-and-signals are horrible to use
from the Haskell side. If the student hasn't already got a good idea of how
to solve this, I fear that this project will be just generate another
unusable set of bindings.


___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] ANN: Haskell Platform 2013.2.0.0

2013-05-28 Thread harry
Good to see it released! Was there a deliberate decision not to build a
Windows x64 platform, or is it just that there wasn't anyone to do it?


___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Infrastructure for testing the impact of a Functor/Applicative/Monad hierarchy

2013-05-18 Thread harry
Niklas Hambüchen mail at nh2.me writes:

 Reading the other thread (Adding Applicative/Functor instances to all
 Monads in GHC) I was wondering if there was infrastructure for testing
 what effect making the often-discussed Functor/Monad change would have:
 How many packages on hackage would break etc.

Some patches for GHC/base are attached to
http://hackage.haskell.org/trac/ghc/ticket/4834. They're a couple of years
old, so they may not apply cleanly, but they might help you in assessing the
impact of such a change.


___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Release Candidates for Haskell Platform 2013.2

2013-05-13 Thread harry
Mark Lentczner mark.lentczner at gmail.com writes:

 Some of the release candidates for Haskell Platform 2013.2 are up.These
are what I expect to simply re-brand as the release, unless anyone
uncovers some issues.

Will they go on
http://trac.haskell.org/haskell-platform/wiki/ReleaseCandidates?
(http://trac.haskell.org/haskell-platform/ has a few outdated links. Does
anyone know what the current links are for the documentation sections?)


___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Interfacing Java/Haskell

2013-05-09 Thread harry
Hans Georg Schaathun georg+haskell at schaathun.net writes:

 Does anyone have experience with integrating Haskell and Java?
 I have done some searching, finding a lot of pointers but hardly
 anything in terms of evaluation, successes, or caveats.  
 
 From what I see Frege looks promising, arguably not haskell I suppose,
 but does it work?  Other projects I have seen appear to have reached 
 a stand-still for ages.

EclipseFP uses Haskell and Java processes talking to each other in JSON.
That's the route which successful multi-lingual projects generally seem to go.


___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Why were datatype contexts removed instead of fixing them?

2013-04-28 Thread harry
Dan Doel dan.doel at gmail.com writes:

 However, another thing to consider is that getting rid of data type
contexts was accepted into the language standard.

... which means that implementers should be free to fix data type contexts
however they like, as they are now complier extensions which won't conflict
with standard Haskell.


___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] Why were datatype contexts removed instead of fixing them?

2013-04-25 Thread harry
If I understand correctly, the problem with datatype contexts is that if we
have e.g.
  data Eq a = Foo a = Foo a
the constraint Eq a is thrown away after a Foo is constructed, and any
method using Foos must repeat Eq a in its type signature.

Why were these contexts removed from the language, instead of fixing them?

PS This is following up on a discussion on haskell-beginners, How to avoid
repeating a type restriction from a data constructor. I'm interested in
knowing whether there's a good reason not to allow this, or if it's just a
consequence of the way type classes are implemented by compilers.


___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Why were datatype contexts removed instead of fixing them?

2013-04-25 Thread harry
Kim-Ee Yeoh ky3 at atamo.com writes:

 data Foo a where
   Foo :: Eq a = a - Foo a
 
 is equivalent to
 
 data Foo a = Eq a = Foo a
 
 but is different from
 
 data Eq a = Foo a = Foo a

... and nothing in GADTs does what one would naively expect the last
declaration to do.


___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Why were datatype contexts removed instead of fixing them?

2013-04-25 Thread harry
Brandon Allbery allbery.b at gmail.com writes:

 As I understand it, it's because fixing them involves passing around a
dictionary along with the data, and you can't do that with a standard
declaration (it amounts to an extra chunk of data that's only *sometimes*
wanted, and that sometimes complicates things). GADTs already have to pass
around extra data in order to support their constructors and destructors;
and, being new and not part of the standard, they don't have backward
compatibility or standards compatibility issues, so they can get away with
including the extra dictionary without breaking existing programs.

But you can't do this with GADTs either?


___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Is there a generic way to detect mzero?

2012-03-26 Thread Harry Terkelsen
Jeff,

I don't think your code works in general, since it is not guaranteed that
x' == mzero is allowed unless (m b) is an instance of Eq. I'm unsure if you
are able to test for mzero in general.

Harry

On Mon, Mar 26, 2012 at 3:11 PM, Jeff Shaw shawj...@msu.edu wrote:


  can :: (MonadPlus m) = (a - m b) - a - Bool
 can f x = case f x of
mzero - False
_ - True


 I got a warning:

 __testError.hs:31:11:
Warning: Pattern match(es) are overlapped
 In a case alternative: _ - ...
 Ok, modules loaded: Main.

 The problem here is that when you match on f x, your first match is an
 identifier that matches anything at all, and binds it to mzero. I think
 what you're looking for is


 can f x = case f x of
x' | x' == mzero - False
_ - True

 Jeff

 __**_
 Haskell-Cafe mailing list
 Haskell-Cafe@haskell.org
 http://www.haskell.org/**mailman/listinfo/haskell-cafehttp://www.haskell.org/mailman/listinfo/haskell-cafe

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] Comparing programs

2006-03-06 Thread Harry Chesley
This is more of an algorithm question than a language question, but any 
insights would be much appreciated.


The problem is to input a series of programs and find previous 
occurrences of the same algorithm.


The programs consist of a set of input parameters (a, b, c, ...), and a 
set of side-effect-free functions (f, g, h, ...). Since the functions 
are side-effect-free, they can be reordered without changing the 
algorithm (f(a), g(b) is the same as g(b), f(a)). Subsequent calls 
of the same function with the same parameters have no effect (f(a), 
f(a) is the same as f(a)); in fact, you can assume duplicates have 
been removed in earlier processing.


But here's the thing that makes it hard (at least for me): two programs 
are considered the same if they can be made to match by rearranging the 
order of the input parameters. I.e., f(a), g(b) is the same as f(b), 
g(a). Although parameters can be reordered, they cannot be substituted 
(f(a), g(b) is _not_ the same as f(a), g(a)).


Example: f(a), g(b), h(a, b) is the same as f(b), g(a), h(b, a) but 
_not_ the same as f(a), g(b), h(b, a).


I need a way to compare the input programs, and preferably to order them.

In Haskell terms, given the programs are represented by a type Prog, I 
want Prog to be a member of class Ord, letting me use tools like 
Data.Map to look up information about previous instances.


I can do a brute-force compare by trying all the parameter permutations, 
but that only gives me Eq, not Ord, and seems terribly inelegant as well.


___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe