Makefile cleanups

1999-07-12 Thread Michael Weber
Hi! I attached a patch that does some additional cleanups to a build tree (equiv.: makes the packager's life easier ;-)) I wasn't sure, which files should go into $(CLEAN_FILES) and which into $(MAINTAINER_CLEAN_FILES), maybe someone could have a look at my choice. regarding the perl scripts:

Re: Problem with 4.03 FFI on Sparc?

1999-07-12 Thread Manuel M. T. Chakravarty
Michael Hobbs [EMAIL PROTECTED] wrote, I wouldn't mind working on this, but I know very little about the SPARC architecture, or the calling conventions. (I don't even know if the stack grows up or down.) I took a look at the assembly output of gcc and got an idea of what's going on, but I

Preprocessor question

1999-07-12 Thread Michael Weber
Hi! Please, can somebody explain, why the preprocessor is hardcoded in the GHC perl scripts? IIRC ghc (the perlscript itself) doesn't even reference $RAWCPP. mkdependHS and hscpp do, but why an absolute path and this obscure "-iprefix" parameter? Again, "-iwithprefix" is never used... Would it

Re: Problem with 4.03 FFI on Sparc?

1999-07-12 Thread Sven Panne
[ redirected to ghu ] "Frank A. Christoph" wrote: I wrote: * A more pressing point is that GHC is tied to x86 machines at moment, see e.g. MBlock.c or Adjustor.c. It is? I thought these were only relevant for the FFI. OK, I was a little vague: MBlock.c is needed by the RTS in any case

Re: calling void foo(void) C functions from haskell

1999-07-12 Thread Manuel M. T. Chakravarty
Peter Amstutz [EMAIL PROTECTED] wrote, I'm experimenting with the haskell FFI, and have run into a odd little problem. For some reason, ghc won't let me import functions with no arguments... [...] And my first try (for.hs) foreign import ccall "hiworld.so" "hiworld" hiworld :: () - IO

RE: Deriving Enum

1999-07-12 Thread Tom Pledger
Wolfram Kahl writes: | To me, it seems unsatisfactory to have a solution to this pure | list problem with auxiliary functions relying on integers. | It turns out to be a nice exercise to implement | | diagonalise :: [[a]] - [a] | | without any reference to numbers. IIRC a (Cantor?)

RE: Deriving Enum

1999-07-12 Thread Frank A. Christoph
Miranda has something called diagonalizing list comprehensions if I recall correctly. I think you would write: [(a,b) // a - [1..], b -[1..]] and the resulting list would be [(1,1), (1,2), (2,1) ...] Haskell has this too. :) The syntax is almost the same:

RE: Deriving Enum

1999-07-12 Thread Tom Pledger
Tom Pledger writes: | diag = foldr (diag2 []) [[]] where |diag2 zs (x:xs) ys = (zipWith (:) (x:zs) ys) ++ diag2 (x:zs) xs ys |diag2 zs [] (_:ys) = (zipWith (:) zs ys) ++ diag2 zs [] ys |diag2 _ _ _ = [] ... which hangs when given a mixture of empty and

Re: Deriving Enum

1999-07-12 Thread Wolfram Kahl
Mark P Jones [EMAIL PROTECTED] writes: Here's my definition of an integer free diagonalization function. [..] As written, I think it is a nice example of programming with higher-order functions, and, in particular, using function composition to construct a pipelined program:

Diagonalisations (was: Re: Deriving Enum)

1999-07-12 Thread Wolfram Kahl
In the meantime I have discovered a flaw in my original diagonalisation in that it looped in finite cases. This can easily be mended: DiagWK1: diag :: [[a]] - [a] diag = f id where f :: ([[a]] - [[a]]) - [[a]] - [a] f a [] = split id (a []) [] f a (l:ls) = split id (a [l]) ls split

Haskell 98

1999-07-12 Thread Simon Peyton-Jones
Folks, For a long time an item on my to-do list has been to update the Haskell 98 bugs page. http://research.microsoft.com/~simonpj/haskell/haskell98-bugs.html I have now done so, adding a dozen or so bug fixes and clarifications that have arisen over the last few months. I believe

RE: Diagonalisations (was: Re: Deriving Enum)

1999-07-12 Thread Simon Peyton-Jones
DiagMPJ 0:00.16 0:02.32 0:37.55 DiagMPJ1 0:00.12 0:01.50 0:23.83 DiagWK1 0:00.12 0:01.34 0:19.02 DiagWK2 0:00.12 0:01.35 0:19.09 DiagWK3 0:00.12 0:01.34 0:18.82 The only thing that surprises me is that the compiler does not do the optimization from DiagWK2 to

Re: Haskell 98

1999-07-12 Thread Antti-Juhani Kaijanaho
On Mon, Jul 12, 1999 at 07:48:30AM -0700, Simon Peyton-Jones wrote: Who owns the copyright? Technically, everybody who has contributed nontrivial amounts of text (not ideas, but text). but given very free-wheeling permission to reproduce the report. I have one request. Language