GHC allow-overlapping-instances

2003-09-28 Thread H X
Hi, Does anyone have ever used this option? I see no difference when I present this program to ghc with -fallow-overlapping-instances on/off: module Test where data T = T data F = F data OR a b = OR a b data AND a b = AND a b class C a b | a -> b instance C (OR T r) T instance C (OR r T) T

Re: Standard Haskell

1998-09-08 Thread Stephen H. Price
l' with no numbering, or maybe 'Haskell!' to emphasize the solidness of the specification. Perhaps 'Just Haskell' is a neat little pun if a more elaborate naming scheme is required. Ste. /^^\ ,---. | Steve H. Price | WebSite:- \__| |

Re: Default Default

1998-11-06 Thread Stephen H. Price
On Thu, 5 Nov 1998, Philip Wadler wrote: > 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 to wait for Haskell 2. Given that, > the conservative design is to leave Int as the default default. > Horses for courses. Just as the in

Re: Questions about Trie

2001-05-17 Thread Arthur H. Gold
> "M. Faisal Fariduddin Attar Nasution" wrote: > > Greeting, I'm a last year student in a computer science field. I'm > currently trying to code an implementation for a compression using > basic Lempel-zif technique. I use a Trie (retrieval) as a data > structure for the dynamic

Notes on Functional Programming With Gofer

1995-06-21 Thread H. Conrad Cunningham
estions you have for its improvement. - Conrad --- H. Conrad Cunningham, D.Sc. | Title: Associate Professor Dept. of Computer & Info. Science | Telephone: (601) 232-5358Fax: 232-5623 University of Mississip

3rd CFP Symp. Functional Programming Languages in Education (FPLE 95)

1995-05-21 Thread Pieter H. Hartel
Call for Papers FPLE'95 Symposium on Functional Programming Languages in Education December 03-06, 1995 Moscow, Russia the symposi

1st CFP Symp. Functional Programming Languages in Education (FPLE 95)

1995-03-22 Thread Pieter H. Hartel
Call for Papers FPLE'95 Symposium on Functional Programming Languages in Education December 03-06, 1995 Moscow, Russia the symposi

U. of Mississippi Faculty Positions

1995-01-10 Thread H. Conrad Cunningham
I posted this to the mailing list back in October or November, but I thought I'd repost it before the 1 February deadline. The ad also appears in the December 1994 CACM. - Conrad Cunningham UNIVERSITY OF M

CFP: Special issue JFP on applications of fucntional languages

1993-11-01 Thread Pieter H. Hartel
Journal of Functional Programming - call for Papers Special issue on state-of-the-art applications of pure functional programming languages A special issue of the Journal of Functional Programming will be devoted to presenting state-of-the-art applications of pure func

Re: GHC licence (was Could Haskell be taken over by Microsoft?)

1998-07-21 Thread H. Conrad Cunningham
Jorgen Frojk Kjaersgaard <[EMAIL PROTECTED]> wrote: > It might be a good idea to publish GHC under the GNU Public License or > something similar. It grants everybody the right to use the software for > any purpose, including making extensions or modifications of it - as long > as the "derived work

More suitable data structure needed

2002-08-20 Thread Dr Mark H Phillips
Hi, Consider the following data structure, effectively of type [[(Int,Int)]]: (2,5) (1,3) (2,0) (2,5) (1,2) (1,1) (1,0) (2,5) (3,1) (1,5) (2,4) (2,0) (1,5) (1,4) (1,3) (1,1) (1,0) (1,5) (1,4) (2,2) (1,0) (1,5) (1,4) (1,2) (2,1) (1,5) (2,3) (1,2) (1,0) (1,5) (2,3) (2,1) (1,5) (1,3) (2,2) (1,1) (1

Re: More suitable data structure needed

2002-08-21 Thread Dr Mark H Phillips
On Wed, 2002-08-21 at 16:52, Hal Daume III wrote: > I would consider using a prefix trie. Unfortunately, such a structure is > not built in to Haskell. Thanks for this! It seems that this kind of data structure is what I am looking for. [begin aside] It seems a pity that one needs to give t

Re: More suitable data structure needed

2002-08-22 Thread Dr Mark H Phillips
On Wed, 2002-08-21 at 17:50, Dylan Thurston wrote: > This is the same as one way of representing search trees, called a > "trie". Two representations in Haskell are: > > > data Trie a = Trie [(a, Trie a)] I touched on the following in my response to Hal Daume's email, but it's probably worth as

Standard Library for text formatting?

2002-08-24 Thread Dr Mark H Phillips
within a fixed column width. Presumably I could write this myself, but it would be better to use a standard library if there is such a thing. Cheers, Mark. -- Dr Mark H Phillips Research Analyst (Mathematician) AUSTRICS - smarter scheduling solutions - www.austrics.com Level 2, 50 Pirie Stre

Pretty printing (was: Standard Library for text formatting?)

2002-08-26 Thread Dr Mark H Phillips
ful to know what libraries are worth investing my time finding out about. (And of course, I'd still love to hear about simple string formatting libraries.) Cheers, Mark. -- Dr Mark H Phillips Research Analyst (Mathematician) AUSTRICS - smarter scheduling solutions - www.austrics.com Le

Why concatMap instead of concat.map?

2002-09-10 Thread Dr Mark H Phillips
Hi, Why does Haskell have a special function called concatMap, rather than people just doing "concat.map"? Is it because concatMap has a more sophisticated implementation than doing just "concat.map"? Cheers, Mark. -- Dr Mark H Phillips Research Analyst (Mathematician)

"where" block local to a guard?

2002-09-16 Thread Dr Mark H Phillips
uld just use t for both! Am I doing something wrongly, or is there a good reason why where isn't allowed to be used in this way? Thanks, Mark. -- Dr Mark H Phillips Research Analyst (Mathematician) AUSTRICS - smarter scheduling solutions - www.austrics.com Level 2, 50 Pirie Street, Adel

Re: "where" block local to a guard?

2002-09-17 Thread Dr Mark H Phillips
Thanks for the explanation! On Tue, 2002-09-17 at 19:07, Brian Boutel wrote: > You can't do this because where clauses are not part of the expression > syntax. If they were, expressions like > > let a=b in c where d=e > or > if a then b else c where d=e > > whould be ambiguous, unl

Good layout style? (was: Re: "where" block local to a guard?)

2002-09-17 Thread Dr Mark H Phillips
On Wed, 2002-09-18 at 01:26, Hamilton Richards wrote: > You can get the effect you're after by using let-expressions: > > > functn :: Int -> Int > > functn i > > | i>5 = let t = functn (i-2) in t * i > > | i>0 = let t = functn (i-1) in t * i > > | otherwise = 1 > > '

Behaviour of div & mod with negative arguments?

2002-09-24 Thread Dr Mark H Phillips
d. Is there a reason why the unary "-" has weak binding? -- Dr Mark H Phillips Research Analyst (Mathematician) AUSTRICS - smarter scheduling solutions - www.austrics.com Level 2, 50 Pirie Street, Adelaide SA 5000, Australia Phone +61 8 8226 9850 Fax +61

Best recursion choice for "penultimax"

2002-11-24 Thread Dr Mark H Phillips
otherwise = (p,q) where (p,q) = maxpenmax ms How do I work out which is best to use? Is there one clear "winner", or will they each have pros and cons? Thanks, Mark. -- Dr Mark H Phillips Research Analyst (Mathematician) AUSTRICS - smarter scheduling solutions - www.austri

RE: Best recursion choice for "penultimax"

2002-11-25 Thread Dr Mark H Phillips
e idea of using "hugs +s". I haven't seen this before. > > reductions cells >my one liner 403511483 >tournament705312288 >your penultimax 1671520180 >your penultimax2 7466

Re: Best recursion choice for "penultimax"

2002-11-25 Thread Dr Mark H Phillips
o remove repeats, keeping only the first. Is there documentation on List.hs, along the lines of the "A Tour of the Haskell Prelude"? Thanks, Mark. -- Dr Mark H Phillips Research Analyst (Mathematician) AUSTRICS - smarter scheduling solutions - www.austrics.com Level 2, 50 Pirie St

Function composition and currying

2003-07-16 Thread Dr Mark H Phillips
at then? Is there a better way? Thanks, Mark. -- Dr Mark H Phillips Research Analyst (Mathematician) AUSTRICS - smarter scheduling solutions - www.austrics.com Level 2, 50 Pirie Street, Adelaide SA 5000, Australia Phone +61 8 8226 9850 Fax +61 8 8231 4821 Email [EMAIL PROTECTED] ___

Re: Function composition and currying

2003-07-25 Thread Dr Mark H Phillips
Thanks to all the people who responded to my question! The solution from Wolfgang Jeltsch: (f.).g was what I was after. But the other responses were useful also. Thanks! Mark. On Thu, 2003-07-17 at 09:57, Dr Mark H Phillips wrote: > Hi, > > Hopefully this is a simple questi

Combining distinct-thread state monads?

2004-01-06 Thread Dr Mark H Phillips
Hi, I am still learning about monads. I have a problem in mind and am wondering whether state monads are able to solve it. The difficulty is that it would necessitate the interaction of two state threads and I'm not sure whether Haskell state monads allow this. Let me explain what I'm getting a

Re: Combining distinct-thread state monads?

2004-01-08 Thread Dr Mark H Phillips
Hi Wolfgang, Thanks for your informative reply. At first I didn't understand it, but a search on "StateT" lead me to the paper "Monad Transformers and Modular Interpreters" by Liang, Hudak and Jones, which clarified some of the ideas for me. The state transformer approach seems to have advantage

Re: GC (was: Stumped without mutation... )

1997-08-26 Thread Paul H J Kelly
A more worthwhile perspective on GC, I think is this: Compare doing simple string manipulations in C versus in Java. In C it's hard work, but you can allocate intermediate arrays statically and program their reuse. In Java, it's easy (so people tend to use a lot of string joins etc), and has to