Bug in ghc-502 with system cmd tmp?

2001-10-15 Thread Bernd Holzmüller
Hi all, I have the following problem on Windows NT using ghc 5.02 from a cygwin bash-shell. Calls to System.system of the form system $ grep -E ++ show str ++ ++ file ++ tmp do not work because of the (ditto with ). Execution yields: grep: : No such file or directory Hugs works

Re: Bug in ghc-502 with system cmd tmp?

2001-10-15 Thread Reuben Thomas
I have the following problem on Windows NT using ghc 5.02 from a cygwin bash-shell. Calls to System.system of the form system $ grep -E ++ show str ++ ++ file ++ tmp do not work because of the (ditto with ). Execution yields: grep: : No such file or directory This is because

cg050 has regressed on stable (ghc-5-02-branch)

2001-10-15 Thread Julian Seward (Intl Vendor)
___ Glasgow-haskell-bugs mailing list [EMAIL PROTECTED] http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs

RE: readFile close behaviour

2001-10-15 Thread Simon Marlow
Simon Marlow [EMAIL PROTECTED] writes: The upshot is that while GHC might notice that you have dropped a Handle, another implementation which doesn't do black holing, stack stubbing, strictness analysis, GC evaluation of selector thunks or any of the other tricks we do to avoid space

RE: Parser panic: Non-exhaustive patterns in case

2001-10-15 Thread Simon Marlow
In GHC 5.02 on Sun Solaris (binary package), running 'ghc-5.02 -c -fglasgow-exts Test.hs' and Test.hs containing the following code: module Test where bimapGRose __ff __a = ((to ((bimapEP epGRose) epGRose)) ((bimapGRose__ __ff) __a)) Gives the following panic message: |

Good Error Message

2001-10-15 Thread Steinitz, Dominic J
Can I just say thank you for the good error message. I'm sure I have used compilers (not Haskell) which would tell you that you have a problem but leave you to find where the two defintions are. Dominic. Encode.hs:8: Ambiguous occurrence `Octet' It could refer to either

Re: Dumb Windows Question

2001-10-15 Thread Reuben Thomas
How do I actually use ghc in Windows (98)? When I installed Hugs, my .hs files got associated with Hugs and if I left-click on a .hs file I have various options to run with. We don't do this with GHC. So do I open a DOS box and invoke ghc or ghci? If so how, what do I have to change to get

RE: ghc-pkg

2001-10-15 Thread Josef Svenningsson
On Mon, 15 Oct 2001, Simon Marlow wrote: With large projects, ghc runs out of heapspace because of too much caching. I think it's more likely that GHC has some space leaks which cause it to hang on to too much memory between compilations. In theory, it only caches the contents of

RE: IO concurrency

2001-10-15 Thread Simon Marlow
Playing with GHC, I met some oddity. Consider the example: import IO import Concurrent import Posix import PosixIO main = do (fdIn, fdIn_send) - createPipe hIn_send - fdToHandle fdIn_send hIn - fdToHandle fdIn -- The waiter is a simple tk/tcl script

Re: IO concurrency

2001-10-15 Thread Max Kirillov
On Mon, Oct 15, 2001 at 04:47:25PM +0100, Simon Marlow wrote: I tried this here on Linux/x86 with 5.02 and it seems to work fine. Instead of the tcl/tk script you mentioned I used a FIFO in /tmp/fifo and made the runProcess just call cat /tmp/fifo. Which GHC version and platform is this on?

let-floating

2001-10-15 Thread Janis Voigtlaender
Hello, I've got a question regarding let-floating [1]. Consider the following two versions of the quicksort algorithm: qsort1 l = f l [] where f [] = (\y - y) f (x:xs) = let (xs_1,xs_2) = part (x) xs in (\y - f xs_1 (x:(f xs_2 y))) qsort2 l = f l

RE: Harmful spammers

2001-10-15 Thread Simon Marlow
There are a couple things to do that can at least cut down on spam. 1) Make sure that your mail gateway, or (in this case) the mailing list host is not an open relay site. It isn't. 2) Every time you get spam, locate all the hosts it came through in the header. Or alternatively

RE: let-floating

2001-10-15 Thread Simon Peyton-Jones
| Is there a compiler (which version?) that optimizes qsort1 to | (essentially) qsort2 ? | | Any hints concerning the possibility/impossibility of this | would be helpful. Thanks and regards, Janis. Alas, (still) not yet. As you say, the transformation depends on spotting a one-shot lambda,

RE: Haskell 98 - Standard Prelude - Floating Class

2001-10-15 Thread Simon Peyton-Jones
Fpr the Revised Haskell 98 report, Russell O'Connor suggests: | Also, I understand you are reluctant to make library changes, | but sinh and cosh can easily be defined in terms of exp | | sinh x = (exp(x) - exp(-x))/2 | cosh x = (exp(x) + exp(-x))/2 | | (source: Calculus Third

Re: bracket_

2001-10-15 Thread Marcin 'Qrczak' Kowalczyk
Sun, 14 Oct 2001 23:25:40 -0400, Ken Shan [EMAIL PROTECTED] pisze: In Haskell's standard IO module, bracket_ is defined to have type IO a - (a - IO b) - IO c - IO c However, in the Exception module in hslibs, bracket_ has type IO a - IO b - IO c - IO c which IMHO is much

Re: Haskell 98 - Standard Prelude - Floating Class

2001-10-15 Thread Jerzy Karczmarczuk
Simon Peyton-Jones: Russell O'Connor suggests: | but sinh and cosh can easily be defined in terms of exp | | sinh x = (exp(x) - exp(-x))/2 | cosh x = (exp(x) + exp(-x))/2 | I suggest removing sinh and cosh from the minimal complete | definition, and add the above defaults. This

Re: Haskell 98 - Standard Prelude - Floating Class

2001-10-15 Thread Lennart Augustsson
2. So, they hold for the Complex numbers as well. The gymnastics with complex sinh and cosh seems to be redundant. Well, I would be a little careful changing these. Some of the definitions in numerical part of the Prelude look more convoluted than they need to be, but it's because they have

RE: Haskell 98 - Standard Prelude - Floating Class

2001-10-15 Thread Lennart Augustsson
| sinh x = (exp(x) - exp(-x))/2 | cosh x = (exp(x) + exp(-x))/2 ... This looks pretty reasonable to me. We should have default methods for anything we can. Why not provide defaults for the inverse functions as well? asinh x = log (x + sqrt (1+x*x)) acosh x = log (x + (x+1) * sqrt

Re: Haskell 98 - Standard Prelude - Floating Class

2001-10-15 Thread Kent Karlsson
- Original Message - From: Jerzy Karczmarczuk [EMAIL PROTECTED] ... Simon Peyton-Jones: Russell O'Connor suggests: | but sinh and cosh can easily be defined in terms of exp | | sinh x = (exp(x) - exp(-x))/2 | cosh x = (exp(x) + exp(-x))/2 | I suggest removing sinh

RE: Haskell 98 - Standard Prelude - Floating Class

2001-10-15 Thread Simon Peyton-Jones
| 1. Actually, I wouldn't even call that default | definitions. These ARE | definitions of sinh and cosh. | | Mathematically, yes. Numerically, no. Even if 'exp' is | implemented with high accuracy, the suggested defaults may | return a very inaccurate (in ulps) result. Take sinh near

RE: Haskell 98 - Standard Prelude - Floating Class

2001-10-15 Thread roconnor
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Mon, 15 Oct 2001, Lennart Augustsson wrote: Why not provide defaults for the inverse functions as well? asinh x = log (x + sqrt (1+x*x)) acosh x = log (x + (x+1) * sqrt ((x-1)/(x+1))) atanh x = log ((x+1) / sqrt (1 - x*x))

RE: Haskell 98 - Standard Prelude - Floating Class

2001-10-15 Thread Lennart Augustsson
That's a good idea too. Is there a reason for defining acosh as above instead of acosh x = log(x + sqrt(x*x-1)) If there is one I can't remember it. :-) -- Lennart ___ Haskell mailing list [EMAIL PROTECTED]

RTA 2002 Call for papers

2001-10-15 Thread Pierre Lescanne
CALL FOR PAPERS RTA 2002 13th International Conference on Rewriting Techniques and Applications July 22--24, Copenhagen, Denmark

RE: Haskell 98 - Standard Prelude - Floating Class

2001-10-15 Thread George Russell
Simon PJ wrote: Fpr the Revised Haskell 98 report, Russell O'Connor suggests: =20 | Also, I understand you are reluctant to make library changes,=20 | but sinh and cosh can easily be defined in terms of exp |=20 | sinh x =3D (exp(x) - exp(-x))/2 | cosh x =3D (exp(x) +

Re: Haskell 98 - Standard Prelude - Floating Class

2001-10-15 Thread Dylan Thurston
On Mon, Oct 15, 2001 at 06:27:52PM +0200, George Russell wrote: Simon PJ wrote: Fpr the Revised Haskell 98 report, Russell O'Connor suggests: =20 | Also, I understand you are reluctant to make library changes,=20 | but sinh and cosh can easily be defined in terms of exp

Re: Haskell 98 - Standard Prelude - Floating Class

2001-10-15 Thread George Russell
Dylan Thurston wrote: [snip] No. As has been pointed out, this is a bad idea numerically because it will give the wrong answer for sinh x for very small values of x. As a matter of fact, you will also get the wrong answer for very large values of x, where exp(x) can overflow even though

Haskell Communities Survey - Second Call for Contributions

2001-10-15 Thread C.Reinke
Dear Haskellers, after the first rush of volunteers seems to have ebbed away, it is probably time for a reminder. First, the good news: We have just about enough topics covered to convince me that it makes sense to go ahead. So the Haskell Communities page has moved to a more permanent

Re: Harmful spammers

2001-10-15 Thread Andre W B Furtado
Or alternatively just report it using Spamcop (http://spamcop.net) or some other reporting tool. Life is just too short to do this by hand every time you get spam. CAUCE (The Coalition Against Unsolicited Commercial Email) seems to me a nice alternative. Check www.cauce.org. On the Haskell

Re: Haskell 98 - Standard Prelude - Floating Class

2001-10-15 Thread Fergus Henderson
On 15-Oct-2001, Simon Peyton-Jones [EMAIL PROTECTED] wrote: The proposal is only to give default declarations in the class defn for sinh, cosh, and perhaps as Lennart suggests asinh, acosh, atanh. They give a reasonable first cut if you don't write definitions yourself. But you can

Re: Haskell 98 - Standard Prelude - Floating Class

2001-10-15 Thread Dylan Thurston
On Mon, Oct 15, 2001 at 03:52:06PM +0200, Kent Karlsson wrote: Simon Peyton-Jones: Russell O'Connor suggests: | but sinh and cosh can easily be defined in terms of exp | sinh x = (exp(x) - exp(-x))/2 | cosh x = (exp(x) + exp(-x))/2 ... This looks pretty reasonable to me. We

Re: Haskell 98 - Standard Prelude - Floating Class

2001-10-15 Thread Jon Fairbairn
In general, this is why LIA-2 (Language Independent Arithmetic, part 2, Elementary numerical functions, ISO/IEC 10967-2:2001) [. . .] This sounds like a very interesting standard. I am constantly annoyed by ISO's attempts to hide their standards; one might wonder what the purpose is of