RE: Small bug in Data.PackedString.splitWithPS

2003-01-13 Thread Simon Marlow
In GHC 5.04.2 this fails: wordsPS (packString a) Cause: typical off-by-one error in libraries/base/Data/PackedString.hs line 289 first_pos_that_satisfies pred ps len n = case [ m | m - [n..len], pred (ps ! m) ] of ^ here

RE: FFI C++ Cygwin

2003-01-13 Thread Simon Peyton-Jones
| It is possible to trick ghc into using cygwin's gcc in mingw-mode, | the following steps works for me to do that: Interesting. The only worry is that the run-time system and libraries are all pre-compiled with the mingw gcc. So it's not clear to me that the process Peter outlines will always

RE: Uninitialized UArray - feature or bug?

2003-01-13 Thread Simon Marlow
This is a little weird: Prelude :m + Data.Array.Unboxed Prelude Data.Array.Unboxed let f () = array (1, 5) [] :: UArray Int Int Prelude Data.Array.Unboxed f () == f () False Are we giving away purity for efficiency? ;) If this behaviour is intended, maybe it should be documented?

Re: openFile and threads

2003-01-13 Thread Matthias Neubauer
Simon Marlow [EMAIL PROTECTED] writes: You might consider bypassing the Handle interface and going to the bare metal using the Posix library, which will cut down on the overhead in openFile. That's what I was fearing. Is the conversion from Haskell Strings to C strings a

RE: openFile and threads

2003-01-13 Thread Simon Marlow
Haskell Strings are a common performance bottleneck; for example when serving files in the Haskell web server I avoided the conversion to Haskell Strings altogether by reading/writing arrays of bytes (see the paper for details). I was curious to see if this is also the case here.

Question about literals in the core-language

2003-01-13 Thread David Sabel
Hello, I'm working at comparing the ghc-core-language with another lambda-calculus. This calculus has no unboxed values, but normal constructors are available. My problem is now: How can I represent the unboxed values in my calculus. More precisely: Can I represent the unboxed values by a finite

WRS 2003 - First Call for Papers

2003-01-13 Thread Salvador Lucas
** *** first call for papers and participation *** ** Third International Workshop on Reduction Strategies in Rewriting and

First APPSEM-II Workshop

2003-01-13 Thread Graham Hutton
+-+ FIRST ANNOUNCEMENT AND CALL FOR PARTICIPATION First APPSEM-II Workshop 26th - 28th March 2003 Nottingham, United Kingdom The first annual

RE: Evaluation Question

2003-01-13 Thread Simon Marlow
For each call, I believe. An exception might be if the call to nco is inlined into the calling function, but this is unlikely as nco is recursive. So, you're probably better off with: nco wn = nco' where wn' = cis wn nco' = 1 : map (wn'*) nco' In which case it will

WRS 2003 - First Call for Papers

2003-01-13 Thread Salvador Lucas
** *** first call for papers and participation *** ** Third International Workshop on Reduction Strategies in Rewriting and

First APPSEM-II Workshop

2003-01-13 Thread Graham Hutton
+-+ FIRST ANNOUNCEMENT AND CALL FOR PARTICIPATION First APPSEM-II Workshop 26th - 28th March 2003 Nottingham, United Kingdom The first annual

type fine until you try to use it

2003-01-13 Thread Abraham Egnor
In a project I'm working on, one data type I've defined is this: data FilterIS = FilterIS { source :: (InputStream s) = s, filter :: Filter } which, to me, just means it holds any instance of the InputStream class and a Filter value. Sure, says ghci, fine by me. However, if I try to do