Re: Type class inference trouble

2001-02-15 Thread Marcin 'Qrczak' Kowalczyk
Thu, 15 Feb 2001 21:08:13 -0500, Dylan Thurston <[EMAIL PROTECTED]> pisze: > On Thu, Feb 15, 2001 at 02:37:09PM -0500, Ken Shan wrote: > > test2 = apply [int 3] (apply [(+)::Int->Int->Int] [int 5]) > > What's strange is that when I tried this just now, the identical line at > the interpreter

Re: Type class inference trouble

2001-02-15 Thread Lars Lundgren
On Thu, 15 Feb 2001, Ken Shan wrote: > Hello all, > > I'm trying to implement some simple natural language semantics with > Haskell (Hugs), and I'm running into trouble with type classes. > Here's what I want to do: Suppose that > > x :: a -> b > y :: a > > then I want to write > >

Re: framework for composing monads?

2001-02-15 Thread Manuel M. T. Chakravarty
Elke Kasimir <[EMAIL PROTECTED]> wrote, > I'm planning a new cli/odbc-based database connectivity library for > Haskell 98 and want to manage hidden state (various management > information) on the Haskell side. > > Some libs. i.e. for gui, extend the IO monad for this using some > "start" func

Re: Haskell Graphics Lib problem

2001-02-15 Thread Henrik Nilsson
Hi Don, > I just bought 'The Haskell School of Expression', so I downloaded the > latest version of Hugs98, February 2001, and the latest version of the > Hugs Graphics Library, 2.0.3. > > Since the documentation mentioned building on Linux, I built and > installed hugs98, ran some tests and fel

Re: Type class inference trouble

2001-02-15 Thread Ken Shan
On 2001-02-15T21:38:54-0500, Dylan Thurston wrote: > > On Thu, Feb 15, 2001 at 02:37:09PM -0500, Ken Shan wrote: > > > test2 = apply [int 3] (apply [(+)::Int->Int->Int] [int 5]) > > What's strange is that when I tried this just now, the identical line at > > the interpreter prompt returned the

Re: Type class inference trouble

2001-02-15 Thread Dylan Thurston
On Thu, Feb 15, 2001 at 09:08:13PM -0500, Dylan Thurston wrote: > On Thu, Feb 15, 2001 at 02:37:09PM -0500, Ken Shan wrote: > > test2 = apply [int 3] (apply [(+)::Int->Int->Int] [int 5]) > > What's strange is that when I tried this just now, the identical line at > the interpreter prompt retu

Re: Type class inference trouble

2001-02-15 Thread Dylan Thurston
On Thu, Feb 15, 2001 at 02:37:09PM -0500, Ken Shan wrote: > test2 = apply [int 3] (apply [(+)::Int->Int->Int] [int 5]) What's strange is that when I tried this just now, the identical line at the interpreter prompt returned the correct answer [8]. This is with Hugs from February 2000; I'm ab

Stack depth

2001-02-15 Thread Sengan
I have a program which works fine, except that for certain (large) input files I have to give it a larger than normal Stack (eg 4M in ghc). GHC allows one to profile heap, but I'd like to know how to profile stack contents. Is there a means with ghc/hugs/or something else? Does anyone have any su

Haskell Graphics Lib problem

2001-02-15 Thread Don Wakefield
I just bought 'The Haskell School of Expression', so I downloaded the latest version of Hugs98, February 2001, and the latest version of the Hugs Graphics Library, 2.0.3. Since the documentation mentioned building on Linux, I built and installed hugs98, ran some tests and felt it was okay. This

Type class inference trouble

2001-02-15 Thread Ken Shan
Hello all, I'm trying to implement some simple natural language semantics with Haskell (Hugs), and I'm running into trouble with type classes. Here's what I want to do: Suppose that x :: a -> b y :: a then I want to write apply x y = x y :: b Moreover, if x :: a y :: a -

Re: Haskell threads & pipes & UNIX processes

2001-02-15 Thread Marcin 'Qrczak' Kowalczyk
Thu, 15 Feb 2001 08:50:41 -0800, Julian Seward (Intl Vendor) <[EMAIL PROTECTED]> pisze: > use the foreign import mechanism to make BZ2_bzopen, > BZ2_bzwrite and BZ2_bzclose available in your program. bzlib and zlib wrappers are available in (for g

RE: Haskell threads & pipes & UNIX processes

2001-02-15 Thread Julian Seward (Intl Vendor)
| So what's going on? How can the goal be achieved? I don't know, but here's a different suggestion, using bzip2 (you could do the same with zlib for .gz files): use the foreign import mechanism to make BZ2_bzopen, BZ2_bzwrite and BZ2_bzclose available in your program. Then: do bz2 <- bzope

Haskell threads & pipes & UNIX processes

2001-02-15 Thread Michael Marte
Hello *, I need to compress the output of my Hakell program. To avoid the creation of huge files, I want to compress before writing by means of gzip or bzip2. However, this seems to be quite involved. I decided to run the compressor with runProcess :: FilePath-- Command

framework for composing monads?

2001-02-15 Thread Elke Kasimir
Does someone like to comment on this? I'm planning a new cli/odbc-based database connectivity library for Haskell 98 and want to manage hidden state (various management information) on the Haskell side. Some libs. i.e. for gui, extend the IO monad for this using some "start" function: main ::

RE: The Do-Let-Braces problem

2001-02-15 Thread Simon Marlow
> Mark Utting writes: > > > fb::IO () > > fb = > > do { > > putStr "Enter Data: "; > > line <- getLine; > > let line2 = line; > > putStr line2; > >} > > > > ERROR "f.hs" (line 13): Syntax error in definition > > (unexpected symbol "putStr

Re: The Do-Let-Braces problem

2001-02-15 Thread Paul Hudak
> fb = > do { > putStr "Enter Data: "; > line <- getLine; > let line2 = line; > putStr line2; >} I suggest doing this: > fb = > do { putStr "Enter Data: " >; line <- getLine >; let line2 = line >; putStr line2 >} wh

Re: The Do-Let-Braces problem

2001-02-15 Thread Malcolm Wallace
Mark Utting writes: > fb::IO () > fb = > do { > putStr "Enter Data: "; > line <- getLine; > let line2 = line; > putStr line2; >} > > ERROR "f.hs" (line 13): Syntax error in definition > (unexpected symbol "putStr") I find it hard to de

WRS'2001 - Second call for papers

2001-02-15 Thread Salvador Lucas Alba
[Apologies for multiple copies of this announcement] ** * 2nd call for papers and participation ** Interna