RE: Replacing the Prelude

2002-06-03 Thread Ashley Yakeley
Ping! At 2002-05-14 07:17, Simon Peyton-Jones wrote: >Ashley writes > >| > I was hoping to do something similar for 'do' notation by redefining >| > (>>), (>>=) etc., but unfortunately GHC is quite insistent >| that 'do' notation quite specifically refers to GHC.Base.Monad > >Dylan replies > >

Re: problems with FFI including h files

2002-06-03 Thread Alastair Reid
> Anyone have any ideas that don't have such a big impact? What we did in Hugs (for GreenCard stuff) was create a header file containing _only_ the things needed by ffi'd code (example attached). Since it was such a short file, it wasn't too hard to avoid nameclashes. This works because the ffi

RE: problems with FFI including h files

2002-06-03 Thread Wolfgang Thaller
On 2002-06-03 12:46:19 +0100 Simon Marlow <[EMAIL PROTECTED]> wrote: >> We really *should* do this, I know. The problem is that it isn't free > by a long shot: it'll make .hc files significantly larger, and obfuscate > a lot of code. > Anyone have any ideas that don't have such a big impact? We

RE: problems with FFI including h files

2002-06-03 Thread Simon Marlow
> Sad, but very true! And GHC's headers are not very nice in > this respect: > > panne@jeanluc:~> grep '#define [^ \t][^ \t] ' > /usr/lib/ghc-5.03/include/* > /usr/lib/ghc-5.03/include/PrimOps.h:#define C 0 > /usr/lib/ghc-5.03/include/PrimOps.h:#define R 1 > /usr/lib/ghc-5.03/in

RE: monomorphism/hugs98/ghc-5.02.3

2002-06-03 Thread Simon Marlow
> However, in ghc-5.02.3 for Haskell 98 (without glasgow extensions) it > seems that is not the case. I _guessed_ that I need to use the flag > -fno-monomorphism-restriction > but I don't know whether I've failed to turn it on or if the > problem is to be found somewhere else. A related problem

Re: Efficient UArray dot-product?

2002-06-03 Thread Jon Fairbairn
> > > Is it possible to write an dot-product function that GHC will compile > to efficient code without using unsafeAt? I've tried and can't. I'm > looking at generic IArray functions pragma-specialized to UArray Int > Double. With unsafeAt the -ddump-simpl output looks optimal to me > (aside