RE: Haskel Type Question

1998-11-09 Thread Frank A. Christoph
>I have two functions > >> fos:: Num a -> [a] -> [a] >> fos a x = fos' a 0 x > >> fos':: Num a -> a -> [a] -> [a] >> fos' _ _ [] = [] >> fos' a y1 (x:xs) = y : fos' a y xs >>where y = a * y1 + x First of all, I think your type signatures are wrong, unless

RE: Haskel Type Question

1998-11-09 Thread Chris Angus
I'm guessing that the problem is that fos -0.5 [1,1,1,1] is being parsed as ((fos) - (0.5)) [1,1,1,1] so that the 0.5 implies an instance of class Fractional which implies by the type of (-) (-) :: Num a => a -> a -> a that fos is al

Re: Haskell 98: getting there

1998-11-09 Thread Hans Aberg
At 03:12 -0800 1998/11/09, Simon Peyton-Jones wrote: >* Default default. Still undecided (sigh). Should it be > (Int, Float) > (Integer, Double) > (Integer, Rational) > Several folk want Integer, but don't say whether they want Float,Double, > Rational. I think the def

RE: MonadZero (concluded)

1998-11-09 Thread Hans Aberg
At 01:58 -0800 1998/11/09, Simon Peyton-Jones wrote: >Following many protests, the right thing to do seems >to be to move MonadPlus to the Monad library. Specifically: > > class Monad m => MonadPlus m where > mzero :: m a > mplus :: m a -> m a -> m a It seems me that the

Re: Default Default

1998-11-09 Thread Colin . Runciman
| Twenty years later, must we really settle for primitive modulo-word-size | arithmetic as the default? | | And many others support Integer over Int as the default default. | | So do I, if it's done right. But we already decided that doing it right | is too hard for Haskell 98; it will have

hugs and ghc compatibility and features

1998-11-09 Thread S. Alexander Jacobson
I have been reading about the integrated runtime system between GHC and Hugs. Now that GHC 4.0 is out, what is the status of the hugs ghc integration project? 1. Does hugs now support mutually recursive modules? 2. Does the new GHC support TREX? If yes, how does one enable it? 3. Are the lite

Re: Haskell 98 progress

1998-11-09 Thread Alex Ferguson
Hi Simon, you spake of simple-context restriction: > My default position is not to change. Question: who, apart from > Ralf, has actually tripped over the lack of contexts of the > form (C (a t1 .. tn)) in Haskell 1.4? *raises hand and jumps up and down* Me, mememe! I provided you with

Re: derive conflicts with multiply-defined and module level import

1998-11-09 Thread Erik Meijer
Lennart wrote: >PS. Or maybe you're firmly in the Microsludge camp now >where source code is never revealed? :-) :-) H/Direct and HaskellScript are neither trick nor treat to them (http://www.opensource.org/halloween.html) yet. Anyway, you probably don't *want* to see their source code, judging

Haskel Type Question

1998-11-09 Thread Matthew Donadio
I have two functions > fos:: Num a -> [a] -> [a] > fos a x = fos' a 0 x > fos':: Num a -> a -> [a] -> [a] > fos' _ _ [] = [] > fos' a y1 (x:xs) = y : fos' a y xs >where y = a * y1 + x Why does > fos -0.5 [ 1, 1, 1, 1 ] give me [a] -> b -> [b] -> [b] i

Re: Two prelude/library matters

1998-11-09 Thread Jerzy Karczmarczuk
Koen Claessen: > Clearly, one would like to define the following default definition as > well: > > negate x = 0 - x Perhaps somebody noticed that already, but also for Fractional objects (which I would love to see belonging to the Field class...) one should have the default: x/y = x * re

Re: Default Default

1998-11-09 Thread Philip Wadler
Colin writes: Another aspect of your comment that troubles me is the strong implication that if the default were Integer, things would not be `done right'. Presumably you mean that it would be painful to make use of a Prelude with Int-based standard functions? If so, then the current

Re: derive conflicts with multiply-defined and module level import

1998-11-09 Thread S. Alexander Jacobson
On Sat, 7 Nov 1998, Fergus Henderson wrote: > > Well, it depends on what you call *strong*. The only reason that I heard is > > that it prevents users from making possibly unwanted errors. > > Another reason is that allowing definitions to be split up > without any special syntax indicating this

A short study of fuzzy oscillator

1998-11-09 Thread Jan Skibinski
I have posted a literate Haskell module "Fuzzy_oscillator" in our collection of Haskell modules: http://www.numeric-quest.com/haskell/ You may also download it as a gzipped bundle (containingg 9 plots) according to downloading instructions on that page. Credits go to Gary Meehan and Mike

RE: Haskell 98: getting there

1998-11-09 Thread Simon Peyton-Jones
> This message summarises where we are. The web page > http://research.microsoft.com/Haskell/haskell98-final.html > is up to date. I am sorry to be so careless. The URL should be http://research.microsoft.com/Users/simonpj/Haskell/haskell98-final.html Simon

Haskell 98: getting there

1998-11-09 Thread Simon Peyton-Jones
Folks, I want to thank everyone who's contributed to the Haskell 98 discussion; it's been very helpful to me. However, to save the bandwidth of those who are less interested, pls consider replying direct to me, and other contributors on a particular topic, where the focus is narrow. (I'd start

RE: MonadZero (concluded)

1998-11-09 Thread Simon Peyton-Jones
Following many protests, the right thing to do seems to be to move MonadPlus to the Monad library. Specifically: class Monad m => MonadPlus m where mzero :: m a mplus :: m a -> m a -> m a filterM :: MonadZero m => (a -> m Bool) -> [a] -> m [a] guard