broken source link

2015-07-24 Thread Christian Maeder
Hi, when trying to look up the original definition for Data.List.transpose in https://downloads.haskell.org/~ghc/latest/docs/html/libraries/Data-List.html I found that the source link https://downloads.haskell.org/~ghc/latest/docs/html/libraries/src/Data-OldList.html#transpose does not work.

Re: [Haskell-cafe] RFC: Native -XCPP Proposal

2015-05-08 Thread Christian Maeder
Hi, using cpphs is the right way to go! Rewriting it from scratch may be a good exercise but is (essentially) a waste of time. However, always asking Malcolm to get source changes into cpphs would be annoying. Therefore it would be great if the sources were just part of the ghc sources (under

Re: [Haskell-beginners] ghc prelude home

2014-12-29 Thread Christian Maeder
23 December 2014 GHC 7.8.4 Released! https://www.haskell.org/ghc/ So 7.8.4 is out! Only the download subpage https://www.haskell.org/ghc/download is not updated yet. Also http://downloads.haskell.org/~ghc/latest/ still refers to http://downloads.haskell.org/~ghc/7.8.3/ (and has a funny

Re: Aliasing current module qualifier

2014-09-29 Thread Christian Maeder
Hi, rather than disambiguating a name from the current module by an abbreviated module name, I would prefer a disambiguation as is done for local names that shadows existing bindings. Then only imported names would need to be qualified (possibly using shorter module names). So names of the

ghc -M

2014-04-23 Thread Christian Maeder
Hi, using ghc -M with ghc-7.8.2 under linux. I got a message: You must specify at least one -dep-suffix (and a failure). http://www.haskell.org/ghc/docs/7.8.1/html/users_guide/separate-compilation.html#makefile-dependencies I've stopped using ghc -M now, but I think it should be documented

Mac CPP problem with ghc-clang-wrapper

2014-03-18 Thread Christian Maeder
Hi, under mavericks using the ghc-clang-wrapper (ghc-7.6) or using ghc-7.8.20140130 I can no longer install the HaXml package. The source line: putStrLn $ part of HaXml-++show MAJOR.MINOR seems to put spaces around the decimal point between MAJOR and MINOR and fails as shown below. Is

haskell xml parsing for larger files?

2014-02-20 Thread Christian Maeder
Hi, I've got some difficulties parsing large xml files ( 100MB). A plain SAX parser, as provided by hexpat, is fine. However, constructing a tree consumes too much memory on a 32bit machine. see http://trac.informatik.uni-bremen.de:8080/hets/ticket/1248 I suspect that sharing strings when

Re: haskell xml parsing for larger files?

2014-02-20 Thread Christian Maeder
should tagsoup be better suited for building trees from large files? C. Am 20.02.2014 15:30, schrieb Chris Smith: Have you looked at tagsoup? On Feb 20, 2014 3:30 AM, Christian Maeder christian.mae...@dfki.de mailto:christian.mae...@dfki.de wrote: Hi, I've got some difficulties parsing

Re: haskell xml parsing for larger files?

2014-02-20 Thread Christian Maeder
On 20 Feb, 2014,at 11:30 AM, Christian Maeder christian.mae...@dfki.de wrote: Hi, I've got some difficulties parsing large xml files ( 100MB). A plain SAX parser, as provided by hexpat, is fine. However, constructing a tree consumes too much memory on a 32bit machine. see http

Re: [Typeable2] Re: ANNOUNCE: GHC 7.8.1 Release Candidate 1

2014-02-20 Thread Christian Maeder
...@haskell.org] On Behalf Of Christian Maeder | Sent: 20 February 2014 15:51 | To: Daniil Frumin | Cc: glasgow-haskell-users@haskell.org | Subject: Re: [Typeable2] Re: ANNOUNCE: GHC 7.8.1 Release Candidate 1 | | Yes, changing Typeable2 to Typeable in: | | {-# LANGUAGE StandaloneDeriving, DeriveDataTypeable

Re: [Solaris bindist] ANNOUNCE: GHC 7.8.1 Release Candidate 1

2014-02-13 Thread Christian Maeder
Am 06.02.2014 15:27, schrieb Páli Gábor János: On Thu, Feb 6, 2014 at 1:39 PM, Merijn Verstraaten mer...@inconsistent.nl wrote: On Feb 6, 2014, at 10:33 , Christian Maeder wrote: or (as I've seen elsewhere) better (?) #!/usr/bin/env bash Definitely use this, FreeBSD (for example) does

[Typeable2] Re: ANNOUNCE: GHC 7.8.1 Release Candidate 1

2014-02-13 Thread Christian Maeder
Hi, with ghc-7.8.20140130 I get the compilation error: Not in scope: type constructor or class ‛Typeable2’ Perhaps you meant ‛Typeable’ (imported from Data.Typeable) What is the recommend way to adjust my code or my dependencies? Cheers Christian Am 03.02.2014 23:35, schrieb Austin

Re: [Solaris bindist] Re: ANNOUNCE: GHC 7.8.1 Release Candidate 1

2014-02-06 Thread Christian Maeder
is compiled on Solaris 11.0 so probably of no use for you on Solaris 10. Also I needed to provide separate tarball of compiled and installed libgmp.so as the Solaris 11's provided does not satisfy GHC requirements and GHC refuses to use that... Karel On 02/ 5/14 04:28 PM, Christian Maeder wrote: Hi

Re: [Solaris bindist] Re: ANNOUNCE: GHC 7.8.1 Release Candidate 1

2014-02-06 Thread Christian Maeder
On 02/ 5/14 04:28 PM, Christian Maeder wrote: Hi, I was surprised to find a Solaris bindist. However, on our SunOS 5.10 ./configure failed miserably. -bash-3.2$ ./configure checking for path to top of build tree... utils/ghc-pwd/dist-install/build/tmp/ghc-pwd-bindist: LD_LIBRARY_PATH=libraries

[OS X mavericks and lifted-base] Re: ANNOUNCE: GHC 7.8.1 Release Candidate 1

2014-02-06 Thread Christian Maeder
cabal install lifted-base finally fails with: [5 of 6] Compiling Control.Exception.Lifted ( Control/Exception/Lifted.hs, dist/build/Control/Exception/Lifted.p_o ) Control/Exception/Lifted.hs:82:1: Warning: The import of ‛Monad’ from module ‛Control.Monad’ is redundant [6 of 6]

[Solaris bindist] Re: ANNOUNCE: GHC 7.8.1 Release Candidate 1

2014-02-05 Thread Christian Maeder
Hi, I was surprised to find a Solaris bindist. However, on our SunOS 5.10 ./configure failed miserably. -bash-3.2$ ./configure checking for path to top of build tree... utils/ghc-pwd/dist-install/build/tmp/ghc-pwd-bindist:

Re: [Solaris bindist] Re: ANNOUNCE: GHC 7.8.1 Release Candidate 1

2014-02-05 Thread Christian Maeder
Am 05.02.2014 16:45, schrieb Roman Cheplyaka: * Christian Maeder christian.mae...@dfki.de [2014-02-05 16:28:50+0100] This happens, because our /bin/sh is a real sh (and not a bash) that only allows to export LD_LIBRARY_PATH as a separate command. You mean it's a real sh and not a POSIX

Re: [Solaris bindist] Re: ANNOUNCE: GHC 7.8.1 Release Candidate 1

2014-02-05 Thread Christian Maeder
Am 05.02.2014 17:06, schrieb Brandon Allbery: Whatever it is, maybe it is a Korn Shell under (older) Solaris, it does not support: The Korn shell is where the `export NAME=value` syntax originated. It is a Bourne Shell under (our) SunOS 5.10 (not to be mixed up with Bourne-again

Re: ANNOUNCE: GHC 7.6.2 Release Candidate 1

2013-01-03 Thread Christian Maeder
worked for me under x86 SunOS 5.10 Cheers Christian OVERALL SUMMARY for test run started at Donnerstag, 3. Januar 2013, 09:52:19 Uhr CET 3402 total tests, which gave rise to 13556 test cases, of which 10 caused framework failures 10486 were skipped 2954 expected passes

Re: [Haskell-cafe] Partial statical linking

2012-09-19 Thread Christian Maeder
Hi, I usually just copy those .a files (that should be linked statically) into `ghc --print-libdir`. HTH Christian Am 19.09.2012 13:06, schrieb Jason Dusek: 2011/12/1 Irene Knapp ireney.kn...@gmail.com: The typical trick to force GHC to statically link a C library is to give the full path

import Module qualified as

2012-08-30 Thread Christian Maeder
Hi, my import lists would look much nicer und could be sorted more easily if the keyword qualified could be placed before the as keyword instead of after import. Therefore I suggest the alternative syntax: import Data.Map qualified as Map This should be fairly simple to implement, if more

Re: GADTs in the wild

2012-08-17 Thread Christian Maeder
Am 15.08.2012 23:13, schrieb Yitzchak Gale: But in my opinion, by far the best solution, using only GADTs, was submitted by Eric Mertens: http://hpaste.org/44469/software_stack_puzzle Eric's solution could now be simplified even further using data kinds. Find attached a version (based on

Re: ANNOUNCE: GHC 7.6.1 Release Candidate 1

2012-08-16 Thread Christian Maeder
Am 14.08.2012 16:08, schrieb Simon Hengel: On Tue, Aug 14, 2012 at 03:47:18PM +0200, Christian Maeder wrote: [...] I cannot test much, as long as the text package cannot be installed. Feel free to use my git version: https://github.com/sol/text Thanks, I've use it for http

Re: GADTs in the wild

2012-08-15 Thread Christian Maeder
a = AccessToken a AccessTokenData C. Am 14.08.2012 18:32, schrieb Felipe Almeida Lessa: 2012/8/14 Christian Maeder christian.mae...@dfki.de: Why not use plain h98? data UserAccessToken = UserAccessToken UserId AccessTokenData UTCTime data AppAccessToken = AppAccessToken AccessTokenData

Re: GADTs in the wild

2012-08-15 Thread Christian Maeder
Am 15.08.2012 17:58, schrieb Felipe Almeida Lessa: On Wed, Aug 15, 2012 at 12:54 PM, Christian Maeder christian.mae...@dfki.de wrote: Well, Either was an adhoc choice and should be application specific. Another h98 solution would be to keep the common part in a single constructor: data

Re: ANNOUNCE: GHC 7.6.1 Release Candidate 1

2012-08-14 Thread Christian Maeder
Am 12.08.2012 21:57, schrieb Ian Lynagh: We are pleased to announce the first release candidate for GHC 7.6.1: http://www.haskell.org/ghc/dist/7.6.1-rc1/ This includes the source tarball, installers for 32bit and 64bit Windows, and bindists for amd64/Linux, i386/Linux, amd64/OSX and

Re: GADTs in the wild

2012-08-14 Thread Christian Maeder
Am 14.08.2012 14:48, schrieb Felipe Almeida Lessa: data AccessToken kind where UserAccessToken :: UserId - AccessTokenData - UTCTime - AccessToken UserKind AppAccessToken :: AccessTokenData - AccessToken AppKind data UserKind data AppKind (Yes, that could be a data

Re: [Haskell-cafe] parsec: parserFail multiple error messages

2012-08-09 Thread Christian Maeder
The error message can be improved in your examples by using count 5 instead of many1. C. Am 08.08.2012 21:24, schrieb silly: I am trying to create a parsec parser that parses an integer and then checks if that integer has the right size. If not, it generates an error. I tried the

Re: [Haskell-cafe] Need help with learning Parsec

2012-07-23 Thread Christian Maeder
Am 22.07.2012 17:21, schrieb C K Kashyap: I've updated the parser here - https://github.com/ckkashyap/LearningPrograms/blob/master/Haskell/Parsing/xml_3.hs The whole thing is less than 100 lines and it can handle comments as well. This code is still not nice: Duplicate code in openTag and

Re: [Haskell-cafe] how to select random elements of a Data.Set?

2012-07-20 Thread Christian Maeder
Am 20.07.2012 15:24, schrieb jwaldmann: Dear all, how would I quickly select an element of a Set (as in Data.Set) uniformly at random? If you use a Map a () (or Map a a) you can use Map.elemAt. The initial conversion is still linear, though. -- | convert a set into an identity map setToMap

Re: [Haskell-cafe] Need help with learning Parsec

2012-07-19 Thread Christian Maeder
Am 19.07.2012 14:53, schrieb C K Kashyap: Dear gentle Haskellers, I was trying to whet my Haskell by trying out Parsec today to try and parse out XML. Here's the code I cam up with - I wanted some help with the gettext parser that I've written. I had to do a dummy char ' ') in there just to

Re: [Haskell-cafe] Need help with learning Parsec

2012-07-19 Thread Christian Maeder
Am 19.07.2012 14:53, schrieb C K Kashyap: innerXML = do x - (try xml | gettext) return x Omit try (and return). xml always starts with whereas gettext never does. C. ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org

Re: [Haskell-cafe] Need help with learning Parsec

2012-07-19 Thread Christian Maeder
Am 19.07.2012 15:14, schrieb Christian Maeder: Am 19.07.2012 14:53, schrieb C K Kashyap: innerXML = do x - (try xml | gettext) return x Omit try (and return). xml always starts with whereas gettext never does. I was wrong, you do not want to swallow an endTag as openTag

Re: [Haskell-cafe] Need help with learning Parsec

2012-07-19 Thread Christian Maeder
Am 19.07.2012 15:26, schrieb Christian Maeder: Am 19.07.2012 15:14, schrieb Christian Maeder: Am 19.07.2012 14:53, schrieb C K Kashyap: innerXML = do x - (try xml | gettext) return x Omit try (and return). xml always starts with whereas gettext never does. I was wrong

Re: [Haskell-cafe] Need help with learning Parsec

2012-07-19 Thread Christian Maeder
by: openTag = try (char '' * many1 (noneOf /)) * char '' C. endTag :: String - Parser String endTag str = string / * string str * char '' Well yes, modified to what Christian Maeder just suggested. Cheers, Simon ___ Haskell-Cafe mailing list

Re: How to describe this bug?

2012-07-11 Thread Christian Maeder
Hi, I think this bug is serious and should be turned into a ticket on http://hackage.haskell.org/trac/ghc/ Would you do so Sönke? The abstraction of floats (Float or Double) is broken if equality considers (random and invisible) excess bits that are not part of the ordinary sign, exponent

Re: How to describe this bug?

2012-07-11 Thread Christian Maeder
Am 11.07.2012 10:25, schrieb Simon Marlow: On 11/07/2012 08:36, Christian Maeder wrote: Hi, I think this bug is serious and should be turned into a ticket on http://hackage.haskell.org/trac/ghc/ Would you do so Sönke? The abstraction of floats (Float or Double) is broken if equality considers

Re: How to describe this bug?

2012-07-10 Thread Christian Maeder
Am 10.07.2012 13:06, schrieb Sönke Hahn: I've attached the code. The code does not make direct use of unsafePerformIO. It uses QuickCheck, but I don't think, this is a QuickCheck bug. The used Eq-instance is the one for Float. The Eq-instance for floats is broken wrt NaN Prelude (0/0 ::

Re: How to describe this bug?

2012-07-10 Thread Christian Maeder
It also works (exposes the bug on x86) without Quickcheck and Doubles: main = prop 6.0 0.109998815 prop m x = do let a = x * m putStrLn (show a ++ foo) print (x * m == a) 0.65999289 foo False The middle line seems to prevent CSE. C. Am 10.07.2012 13:06, schrieb Sönke Hahn:

Re: [Haskell-cafe] Associative prefix operators in Parsec

2012-03-12 Thread Christian Maeder
Am 08.03.2012 17:16, schrieb Troels Henriksen: Christian Maederchristian.mae...@dfki.de writes: The simplest solution is to parse the prefixes yourself and do not put it into the table. (Doing the infixes and | by hand is no big deal, too, and possibly easier then figuring out the

Re: [Haskell-cafe] Associative prefix operators in Parsec

2012-03-08 Thread Christian Maeder
The simplest solution is to parse the prefixes yourself and do not put it into the table. (Doing the infixes and | by hand is no big deal, too, and possibly easier then figuring out the capabilities of buildExpressionParser) Cheers C. Am 07.03.2012 13:08, schrieb Troels Henriksen:

auto-orphans?

2012-02-07 Thread Christian Maeder
Hi, in http://www.haskell.org/ghc/docs/7.4.1/html/users_guide/options-sanity.html I've found no description for -fwarn-auto-orphans Cheers Christian ___ Glasgow-haskell-users mailing list Glasgow-haskell-users@haskell.org

Re: GHC 7.0.4 recursion while trying to derive type

2012-01-09 Thread Christian Maeder
Am 08.01.2012 04:39, schrieb Bogdan Opanchuk: Hello, Consider the following code: {-# LANGUAGE MultiParamTypeClasses, FlexibleInstances, OverlappingInstances, UndecidableInstances, FunctionalDependencies #-} We have also such (cruel) code using these extension. t4.hs:17:31:

Re: GHC 7.0.4 recursion while trying to derive type

2012-01-09 Thread Christian Maeder
Am 09.01.2012 13:16, schrieb Christian Maeder: I cannot answer this, but our code also compiles with ghc-7.2.2 using a lower context-stack (of 26). Apologies, I've just re-checked and noticed that our code changed and needs consistently -fcontext-stack=26 for ghc-7.2.2 and ghc-7.0.4 (and ghc

Re: [Haskell-cafe] How to split this string.

2012-01-05 Thread Christian Maeder
Am 05.01.2012 11:57, schrieb Steve Horne: [...] groupCut :: (x - x - Bool) - [x] - [[x]] [...] How about a break function that respects an escape character (1. arg) (and drops the delimiter - 2. arg) and use this function for unfolding? import Data.List break' :: (a - Bool) - (a - Bool) -

Re: [Haskell-cafe] How to split this string.

2012-01-05 Thread Christian Maeder
Am 05.01.2012 13:04, schrieb Steve Horne: [...] I was going to accuse you of cheating - who says there's a spare value to use? - but you seem to be using Maybe, so well played. You're also using unfoldr, which I really must play with a bit - I don't really have a feel for how unfolding works

Re: [Haskell-cafe] How to split this string.

2012-01-04 Thread Christian Maeder
Am 04.01.2012 17:47, schrieb Steve Horne: On 02/01/2012 11:12, Jon Fairbairn wrote: maxm...@mtw.ru writes: I want to write a function whose behavior is as follows: foo string1\nstring2\r\nstring3\nstring4 = [string1, string2\r\nstring3, string4] Note the sequence \r\n, which is ignored. How

Re: [Haskell-cafe] How to split this string.

2012-01-02 Thread Christian Maeder
Am 02.01.2012 10:44, schrieb max: I want to write a function whose behavior is as follows: foo string1\nstring2\r\nstring3\nstring4 = [string1, string2\r\nstring3, string4] Note the sequence \r\n, which is ignored. How can I do this? replace the sequence by something unique first, i.e. a

ghc-7.4.1-rc1 recompilation checking

2011-12-27 Thread Christian Maeder
Hi, full recompilation with ghc-7.4.1-rc1 is already triggered by a changed -o option, which is inconvenient when creating different binaries with shared modules. (see below) It is no problem if I always omit the -o option and get binaries named like my input file, though. Can/should this

Re: [Haskell-cafe] Operator precedence and associativity with Polyparse

2011-10-26 Thread Christian Maeder
Am 26.10.2011 01:49, schrieb Tom Hawkins: Can someone provide guidance on how handle operator precedence and associativity with Polyparse? Do you mean parsing something like 1 + 2 * 3 ? I don't think there's any real difference in using Polyparse vs Parsec for this, except for doing p

Re: [Haskell-cafe] ANNOUNCE: vector-bytestring-0.0.0.0

2011-10-21 Thread Christian Maeder
Am 20.10.2011 21:43, schrieb Michael Snoyman: On Wed, Oct 19, 2011 at 9:29 PM, Ketil Maldeke...@malde.org wrote: Michael Snoymanmich...@snoyman.com writes: sense to try and pursue something like what you're suggesting, but I think the default Show (Vector Word8) should be the one most

Re: [Haskell-cafe] ANNOUNCE: vector-bytestring-0.0.0.0

2011-10-18 Thread Christian Maeder
Am 12.10.2011 16:02, schrieb Bas van Dijk: API DOCS http://hackage.haskell.org/package/vector-bytestring-0.0.0.0 you could re-export VS.empty, VS.singleton, etc. directly. Cheers Christian -- | /O(1)/ The empty 'ByteString' empty :: ByteString empty = VS.empty {-# INLINE empty #-} -- |

Re: [Haskell-cafe] ANNOUNCE: vector-bytestring-0.0.0.0

2011-10-17 Thread Christian Maeder
I think the cleanest solution (just from a theoretical point of view) is to use a newtype for your byte strings. - it should have the same performance - allows to make ByteString really abstract when hiding the newtype constructor - is portable and supplies control over all other instances

Re: [Haskell-cafe] ANNOUNCE: vector-bytestring-0.0.0.0

2011-10-17 Thread Christian Maeder
Am 17.10.2011 11:10, schrieb Ertugrul Soeylemez: So please, please, please, if you decide to use a newtype, do /not/ hide the constructor. The better alternative to not hiding the constructor is to supply conversion functions that may or may not do more than the constructor and selector and

Re: [Haskell-cafe] ANNOUNCE: vector-bytestring-0.0.0.0

2011-10-17 Thread Christian Maeder
Am 17.10.2011 12:14, schrieb Bas van Dijk: On 17 October 2011 10:18, Christian Maederchristian.mae...@dfki.de wrote: I think the cleanest solution (just from a theoretical point of view) is to use a newtype for your byte strings. - it should have the same performance - allows to make

Re: [Haskell-cafe] ANNOUNCE: vector-bytestring-0.0.0.0

2011-10-17 Thread Christian Maeder
Am 17.10.2011 12:19, schrieb Michael Snoyman: [...] Also, aren't there a few documented cases where newtypes prevent certain GHC rewrite rules from firing? This would be possible to find out with a wrapper module. Cheers Christian I don't see any strong argument to avoid what appears to be

Re: [Haskell-cafe] ANNOUNCE: vector-bytestring-0.0.0.0

2011-10-17 Thread Christian Maeder
Am 17.10.2011 17:26, schrieb Bas van Dijk: On 17 October 2011 13:12, Christian Maederchristian.mae...@dfki.de wrote: So your package basically supports an unfortunate mix of bytestring and vector functions? No, vector-bytestring exports the same API as bytestring (except for the Show and

Re: [Haskell-cafe] ANNOUNCE: vector-bytestring-0.0.0.0

2011-10-14 Thread Christian Maeder
Am 12.10.2011 16:02, schrieb Bas van Dijk: All your ByteString are belong to us... Hello, I'm pleased to announce the beta release of vector-bytestring. This library provides the type ByteString which is defined as a type synonym for a storable Vector of Word8s (from the vector package):

Re: [Haskell-cafe] Question on definition of `parse' function in Parsec library.

2011-10-10 Thread Christian Maeder
Am 08.10.2011 16:04, schrieb Captain Freako: Hi all, In this definition from the Parsec library: parse :: (Stream s Identity t) = Parsec s () a - SourceName - s - Either ParseError a parse p = runP p () what's the significance of `Identity t'? (`t' isn't used

Re: Please apply the comparison function given to nubBy to elements of the list in the order in which they occur in the list.

2011-09-28 Thread Christian Maeder
In case you further want to discuss this, I've re-opened http://hackage.haskell.org/trac/ghc/ticket/2528#comment:10 So, I'm against your proposal, Cale, but suggest that you revert the order in your example (if you want to exploit this behavior). Cheers Christian Am 08.09.2011 02:07, schrieb

Re: Please apply the comparison function given to nubBy to elements of the list in the order in which they occur in the list.

2011-09-21 Thread Christian Maeder
Am 20.09.2011 20:21, schrieb Edward Kmett: [...] I would suggest you rephrase this as a formal proposal, then I can happily vote +1. Seeing the wonderful interrelation between elem, nub, nubBy and i.e. unionBy eq xs ys = xs ++ foldl (flip (deleteBy eq)) (nubBy eq ys) xs intersectBy eq

Re: [Haskell-cafe] Parsec line number off-by-one

2011-09-21 Thread Christian Maeder
Hi, 1. your lookAhead is unnecessary, because your items (atomNames) never start with %. 2. your try fails in (line 12, column 1), because the last item (aka atomName) starts consuming \n, before your eol parser is called. So rather than calling spaces before every real atom, I would call

Re: Please apply the comparison function given to nubBy to elements of the list in the order in which they occur in the list.

2011-09-20 Thread Christian Maeder
Looking at the code of nubBy http://www.haskell.org/ghc/docs/latest/html/libraries/base-4.4.0.0/src/Data-List.html#nubBy nubBy :: (a - a - Bool) - [a] - [a] #ifdef USE_REPORT_PRELUDE nubBy eq [] = [] nubBy eq (x:xs) = x : nubBy eq (filter (\ y - not (eq x

Re: Please apply the comparison function given to nubBy to elements of the list in the order in which they occur in the list.

2011-09-20 Thread Christian Maeder
==y || elem x ys notElem _ []= True notElem x (y:ys)= x /= y notElem x ys #endif So the proposal should be to swap the arguments in x==y and x /= y (above) which would also fix the nub implementation! C. Am 20.09.2011 13:46, schrieb Christian Maeder: Looking at the old tickets http

Re: [Haskell-cafe] GHC/Cabal on AFS

2011-09-06 Thread Christian Maeder
I had similar problems under Solaris with ghc binaries compiled using gcc-4.3.3 http://hackage.haskell.org/trac/ghc/ticket/5013 C. Am 05.09.2011 19:06, schrieb Tristan Ravitch: I have the Haskell Platform (and my home directory with my cabal-installed packages) installed on an AFS (a

Re: [Haskell-cafe] Trouble with readProcess

2011-08-11 Thread Christian Maeder
Am 11.08.2011 16:45, schrieb Charles-Pierre Astolfi: Hi -cafe, I'm using readProcess and I don't know how to handle this issue: readProcess cmd [opt1,opt2] seems to execute the following: are you sure that your argument strings do not contain the quotes, possibly by calling show on

FlexibleInstances Re: ANNOUNCE: GHC 7.2.1 Release Candidate 1

2011-08-05 Thread Christian Maeder
Hi, I've noticed that with ghc-7.2 many modules with LANGUAGE TypeSynonymInstances now also require FlexibleInstances Two examples are in the HTTP package Network.TCP and Network.BufferType Was ghc-7.0 wrong about this, before? Cheers Christian Am 29.07.2011 20:21, schrieb Ian Lynagh: We

Re: FlexibleInstances Re: ANNOUNCE: GHC 7.2.1 Release Candidate 1

2011-08-05 Thread Christian Maeder
I've just found http://hackage.haskell.org/trac/ghc/ticket/5377 which explains it. C. Am 05.08.2011 12:56, schrieb Christian Maeder: Hi, I've noticed that with ghc-7.2 many modules with LANGUAGE TypeSynonymInstances now also require FlexibleInstances Two examples are in the HTTP package

Re: [Haskell-cafe] Regular Expression Parsing via derivatives

2011-08-02 Thread Christian Maeder
Am 01.08.2011 17:51, schrieb Alex Clemmer: Hi Haskell people, I've been snooping through various mailing lists and the current Haskell implementation of regular expressions and I was wondering if there has been a discussion about implementing regex parsing with derivatives. If so, I haven't

Re: [Haskell-cafe] Inconsistent trailing comma in export list and record syntax

2011-07-12 Thread Christian Maeder
Generally allowing trailing (or leading or repeated) commas would clash with tuple sections. Also the pair constructor (,) is a special case. http://www.haskell.org/ghc/docs/7.0.4/html/users_guide/syntax-extns.html#tuple-sections Cheers Christian Am 11.07.2011 12:09, schrieb Joachim Breitner:

Re: Compiling 32-bit GHC on a 64-bit Mac

2011-06-06 Thread Christian Maeder
Am 06.06.2011 12:08, schrieb Johan Tibell: On Sun, Jun 5, 2011 at 2:38 PM, Ian Lynaghig...@earth.li wrote: On Sun, Jun 05, 2011 at 02:10:39PM +0200, Johan Tibell wrote: I need to reproduce a bug that only appears on 32-bit machines. I don't own such a machine but I was hoping I could compile

Re: [Haskell-cafe] Programming Chalenges: The 3n+1 problem

2011-04-14 Thread Christian Maeder
Am 14.04.2011 12:29, schrieb Dmitri O.Kondratiev: 3n+1 is the first, warm-up problem at Programming Chalenges site: http://www.programming-challenges.com/pg.php?page=downloadproblemprobid=110101format=html http://www.programming-challenges.com/pg.php?page=downloadproblemprobid=110101format=html

Proposal: add ghc -fwarn-non-ascii warning flag

2011-04-07 Thread Christian Maeder
similar in spirit to the -fwarn-tabs warning. C. P.S. In the mean time you may use http://projects.haskell.org/style-scanner/ (Caveat, it crashes on latin1 files when compiled with ghc-6.12 or greater.) ___ Haskell-prime mailing list

Re: [Colin Paul Adams] Re: Proposal: Define UTF-8 to be the encoding of Haskell source files

2011-04-07 Thread Christian Maeder
Am 07.04.2011 13:09, schrieb Roel van Dijk: Please take a look at the following file: http://code.haskell.org/numerals/src/Text/Numeral/Language/ZH.hs Great, that file made my firefox open infinitely many tabs (so that I had to close it). C. ___

Re: [Colin Paul Adams] Re: Proposal: Define UTF-8 to be the encoding of Haskell source files

2011-04-07 Thread Christian Maeder
Am 07.04.2011 13:09, schrieb Roel van Dijk: Please take a look at the following file: http://code.haskell.org/numerals/src/Text/Numeral/Language/ZH.hs The code would not suffer much if it were pure ASCII. I would prefer (ascii) haddock links to explain the various code points. C.

Re: [Haskell-cafe] how to optmize this code?

2011-03-31 Thread Christian Maeder
Am 31.03.2011 05:59, schrieb Felipe Almeida Lessa: On Wed, Mar 30, 2011 at 2:39 PM, Gilberto Garciagiba@gmail.com wrote: fkSum :: Int - [Int] - Int fkSum a [] = 0 fkSum a (b) = foldl (+) 0 (filter (\x - isMultiple x b) [1..a]) Daniel Fischer and Yves Parès gave you good suggestions

Re: Fix context reduction stack overflow in dimensional

2011-03-29 Thread Christian Maeder
Am 29.03.2011 13:46, schrieb Bas van Dijk: Dear Bjorn, Attached is a patch that fixes a context reduction stack overflow in your dimensional package. I noticed something weird though (that's why I'm CCing the ghc list). When I cabal build dimensional-0.8.2 I first get the context reduction

Re: ghc fails with HOME not set, fixing right now

2011-03-25 Thread Christian Maeder
ghc should not fail if HOME is not set. It certainly cannot look up local packages then, but ghc should work without those, too. ghc is a compiler like gcc. Does gcc need HOME? Cheers Christian Am 25.03.2011 08:26, schrieb Joachim Breitner: Hi, new FTBFS coming up: ghc fails if HOME is not

Re: GHC7 (on OSX.5)

2011-03-22 Thread Christian Maeder
Am 21.03.2011 18:40, schrieb wren ng thornton: On 3/21/11 4:16 AM, Christian Maeder wrote: Am 20.03.2011 20:01, schrieb wren ng thornton: So I'm having a go of installing ghc-7.0.2 and haskell-platform-2011.2.0.0 on OSX 10.5. Since 10.5 is no longer supported I've had to compile from source

Re: GHC7 (on OSX.5)

2011-03-21 Thread Christian Maeder
Am 20.03.2011 20:01, schrieb wren ng thornton: So I'm having a go of installing ghc-7.0.2 and haskell-platform-2011.2.0.0 on OSX 10.5. Since 10.5 is no longer supported I've had to compile from source. The good news is, so far as I can tell, everything works right out of the box.[1] [...]

Re: cabal install network was: Re: ANNOUNCE: GHC 7.0.2 Release Candidate 2

2011-03-17 Thread Christian Maeder
Am 23.02.2011 15:41, schrieb Ian Lynagh: On Tue, Feb 22, 2011 at 05:17:35PM +0100, Christian Maeder wrote: Am 22.02.2011 14:47, schrieb Ian Lynagh: On Tue, Feb 22, 2011 at 09:59:20AM +0100, Christian Maeder wrote: Where does cabal get its flags from? (hardcoded?) From the C compiler flags

Re: Data.ByteString.Lazy.ByteString vs Data.ByteString.Lazy.Internal.ByteString

2011-03-14 Thread Christian Maeder
Am 14.03.2011 06:26, schrieb C K Kashyap: Looks like a job for Data.Binary. I'd like to use it with just the libraries that are part of the platform I forgot to mention, Data.Binary does not seem to be in the platform. Right, it is not in the platform, but I would recommend

testsuite missing was: Re: ANNOUNCE: GHC version 7.0.2

2011-03-14 Thread Christian Maeder
Why is the file still not being updated? http://www.haskell.org/ghc/dist/7.0.2/testsuite-7.0.2.tar.bz2 C. Am 10.03.2011 03:22, schrieb Jens Petersen: On 4 March 2011 23:14, Christian Maeder christian.mae...@dfki.de wrote: http://www.haskell.org/ghc/dist/7.0.2/testsuite-7.0.2.tar.bz2

Re: [Haskell-cafe] Data.ByteString.Lazy.ByteString vs Data.ByteString.Lazy.Internal.ByteString

2011-03-14 Thread Christian Maeder
Am 14.03.2011 06:26, schrieb C K Kashyap: Looks like a job for Data.Binary. I'd like to use it with just the libraries that are part of the platform I forgot to mention, Data.Binary does not seem to be in the platform. Right, it is not in the platform, but I would recommend

Re: ghc-7.0.2 on macports wanted

2011-03-11 Thread Christian Maeder
Am 11.03.2011 11:32, schrieb Max Bolingbroke: On 10 March 2011 17:51, Christian Maeder christian.mae...@dfki.de wrote: Why does the base package depend on iconv only on macs? iconv is not needed under linux or solaris (unless you install haskeline, which is not in the platform. I don't have

ghc-7.0.2 on macports wanted

2011-03-10 Thread Christian Maeder
Dear All, we would appreciate a ghc-7.0.2 distribution package via macports, because we intend to make macports packages based on ghc and gtk+2.0. Libraries from the Haskell-Platform would be nice, too. Was macports given up? Via port pkg we want to create binary mac packages, however, these

Re: ghc-7.0.2 on macports wanted

2011-03-10 Thread Christian Maeder
. The official ghc is linked and links against /usr/lib/libiconv.dylib, which makes a problem as soon as -L/opt/local/lib is added by some cabal package. But this can be fixed by adding -L/usr/lib as first argument to ghc. C. On Thu, Mar 10, 2011 at 5:50 AM, Christian Maeder christian.mae...@dfki.de wrote

Re: ghc-7.0.2 on macports wanted

2011-03-10 Thread Christian Maeder
. On Thu, Mar 10, 2011 at 6:58 AM, Christian Maeder christian.mae...@dfki.de wrote: Am 10.03.2011 15:52, schrieb Don Stewart: Does MacPorts still interact badly with libiconv? (The system and MacPorts versions out of sync, making Haskell unbuildable unless in MacPorts). ghc from macports was build

Re: [Haskell-cafe] Update Cabal

2011-03-10 Thread Christian Maeder
What are the arguments for updating? Are you using ghc-7.0.2? Wait for Haskell Platform 2011.2.0.0 that will be based on cabal-install-0.10.2! Cheers Christian Am 10.03.2011 11:27, schrieb Hauschild, Klaus (EXT): Hallo, I'm using Haskell Platform 2010.2.0.0 on a Windows XP machine. This

big hello world binary on 32bit intel MacOS

2011-03-09 Thread Christian Maeder
Hi, compiling a simple putStrLn Hello program creates binaries of size: ghc-6.12.3: 719K ghc-7.0.1: 7,4M ghc-7.0.2: 6,9M otool -L for the ghc-7 binaries displays: /usr/lib/libiconv.2.dylib (compatibility version 7.0.0, current version 7.0.0) /usr/lib/libSystem.B.dylib

no testsuite? Re: ANNOUNCE: GHC version 7.0.2

2011-03-09 Thread Christian Maeder
I still cannot make sense out of this testsuite-7.0.2.tar.bz2 C. Am 04.03.2011 15:14, schrieb Christian Maeder: http://www.haskell.org/ghc/dist/7.0.2/testsuite-7.0.2.tar.bz2 This archive does not seem to have the actual tests inside the testsuite subdirectory. At least the README

Re: big hello world binary on 32bit intel MacOS

2011-03-09 Thread Christian Maeder
I've created a ticket for it: http://hackage.haskell.org/trac/ghc/ticket/5008 C. Am 09.03.2011 14:06, schrieb Christian Maeder: Hi, compiling a simple putStrLn Hello program creates binaries of size: ghc-6.12.3: 719K ghc-7.0.1: 7,4M ghc-7.0.2: 6,9M otool -L for the ghc-7 binaries

Re: [Haskell-cafe] Overlaping Parsec rules

2011-03-09 Thread Christian Maeder
Am 08.03.2011 13:50, schrieb Christian Maeder: Am 08.03.2011 13:35, schrieb Hauschild, Klaus (EXT): Hi Christian, Thank you for your help. Now the current version of Parse.hs (http://code.google.com/p/hgmltracer/source/browse/trunk/hGmlTracer/src/Gml/Parse.hs) works well for the test file

Re: [Haskell-cafe] Overlaping Parsec rules

2011-03-09 Thread Christian Maeder
Am 09.03.2011 14:44, schrieb Christian Maeder: Am 08.03.2011 13:50, schrieb Christian Maeder: Am 08.03.2011 13:35, schrieb Hauschild, Klaus (EXT): Hi Christian, Thank you for your help. Now the current version of Parse.hs (http://code.google.com/p/hgmltracer/source/browse/trunk/hGmlTracer

Re: [Haskell-cafe] have anyone tried GHC 7.0.2

2011-03-08 Thread Christian Maeder
What does ghc-pkg list and ghc-pkg check say? Cabal-1.10.1.0, directory-1.1.0.0 and process-1.0.1.5 should be there after installation of GHC 7.0.2. (I've actually installed cabal-install-0.10.0 using an older cabal, but that does not work on macs and may not be the recommended way.) I think

Re: [Haskell-cafe] Overlaping Parsec rules

2011-03-08 Thread Christian Maeder
lexeme.) C. The redefinition of space is not necessary, it was copied from another tutorial code. How I write a version of parseGml that get gml token separated by any white space (space, tab, newline)? Thanks -Ursprüngliche Nachricht- Von: Christian Maeder [mailto:christian.mae

Re: [Haskell-cafe] Overlaping Parsec rules

2011-03-08 Thread Christian Maeder
token separated by any white space (space, tab, newline)? Thanks -Ursprüngliche Nachricht- Von: Christian Maeder [mailto:christian.mae...@dfki.de] Gesendet: Montag, 7. März 2011 14:18 An: Hauschild, Klaus (EXT) Cc: haskell-cafe@haskell.org Betreff: Re: Overlaping Parsec rules

Re: [Haskell-cafe] Overlaping Parsec rules

2011-03-08 Thread Christian Maeder
- Von: Christian Maeder [mailto:christian.mae...@dfki.de] Gesendet: Montag, 7. März 2011 14:18 An: Hauschild, Klaus (EXT) Cc: haskell-cafe@haskell.org Betreff: Re: Overlaping Parsec rules Am 07.03.2011 13:48, schrieb Hauschild, Klaus (EXT): Thanks Christian, I adapted the keyword parser

Re: [Haskell-cafe] Overlaping Parsec rules

2011-03-08 Thread Christian Maeder
from another tutorial code. How I write a version of parseGml that get gml token separated by any white space (space, tab, newline)? Thanks -Ursprüngliche Nachricht- Von: Christian Maeder [mailto:christian.mae...@dfki.de] Gesendet: Montag, 7. März 2011 14:18 An: Hauschild, Klaus

Re: [Haskell-cafe] Overlaping Parsec rules

2011-03-07 Thread Christian Maeder
You should parse keywords using: keyword s = try (string s) notFollowedBy (letter | digit) C. Am 07.03.2011 11:34, schrieb Hauschild, Klaus (EXT): Hi, to solve this ICFP task _http://www.cs.cornell.edu/icfp/task.htm_ I'm currnetly working on the parser. With the hint from Thu (reading

  1   2   3   4   5   6   7   8   9   10   >