Re: GHC, functional dependency, rank-2 type

2004-01-13 Thread oleg
John Tromp wrote: > >>instance (Bar a) => Foo a > I have tried to write code myself like in the last line, > stating that any instance of one class should also be > an instance of another class. But Hugs would complain about > it. You're right. Hugs needs to be told that the code is in an extend

ANNOUNCE: new FGL version (Jan 2004)

2004-01-13 Thread Martin Erwig
FGL - A Functional Graph Library, Version: January 2004 === I am happy to announce a new release of the Functional Graph Library for Haskell, a collection of graph algorithms and tools. New in this release: * bug fix for nearestNode (src/Data/G

overlapping instances and modules

2004-01-13 Thread Iavor S. Diatchki
hello, i am a bit stuck on the following problem, which seems to be GHC related. consider the following two modules: > {-# OPTIONS -fglasgow-exts -fallow-overlapping-instances #-} > module Test where > > data T m a = T (m a) > > class C m where get :: m a > > instance C (T m) > instance C m => C (t

graphs and trees again

2004-01-13 Thread Wolfgang Jeltsch
Hello, for my studies I recently needed graph and tree handling code. Because nothing I found seemed to satisfy my needs, I finally started writing my own graph and tree module. I was especially disappointed with Data.Graph and Data.Tree. The reasons are: * The Implementation of the type

C++ preprocessor, Was: Uniqueness types in FC++

2004-01-13 Thread Jan Kybic
> as well. But if we're going to do this, we may as well define a new > "FC++ language" in its own right and write a compiler which converts > this into C++ code. Yes! I fully back this approach, please let me know if you start a project like this. I would propose to use a Haskell-like language a

CFP: Workshop on Constraint Programming and Constraint for Verification (CP+CV'04)

2004-01-13 Thread Giorgio Delzanno
CALL FOR PAPERS Workshop on Constraint Programming and Constraint for Verification (CP+CV'04) March 28, Barcelona, Spain at the European Joint Conferences on

Re: data label overloading

2004-01-13 Thread Hal Daume III
> data Foo1 = Foo1 {size :: Int ...} > ... > data Foo2 = Foo2 {size :: Int ...} > ... > f x y z = let size = Foo1..size > in > (size x) + (size y) + (Foo2..size z) How does this save you typing over: data Foo1 = Foo1 { foo1_size :: Int } data Foo2 = Foo2 { foo

Re: GHC, functional dependency, rank-2 type

2004-01-13 Thread John Tromp
[EMAIL PROTECTED] wrote: There appears to be a problem with GHC's handling of multi-parameter constraints with functional dependencies in the context of rank-2 types. The problem is not present in Hugs. Let us first consider a simple example: module Test where class Foo a class Bar a data Obj =

Re: [Parsec] Extracting line and column numbers

2004-01-13 Thread Christian Maeder
Tomasz Zielonka wrote: On Tue, Jan 13, 2004 at 12:44:10PM +0100, Stefan Holdermans wrote: abstract and I cannot extract the line and column numbers from a SourcePos value. What are my options? What about these? sourceColumn :: SourcePos -> Column sourceLine :: SourcePos -> Line These signatu

Re: [Parsec] Extracting line and column numbers

2004-01-13 Thread Tomasz Zielonka
On Tue, Jan 13, 2004 at 12:44:10PM +0100, Stefan Holdermans wrote: > Hi, > > I'm using the Parsec library to parse strings for a small experimental > language. I'd like to decorate each node in the abstract syntax tree with > a pair (Int, Int) that represents the line and column number in the > st

data label overloading

2004-01-13 Thread Serge D. Mechveliani
Dear Haskellers, It is desirable to have shorter names for the data labels. Making a module out of a labeled data declaration does not look convenient. Providing the corresponding class operation is not always convenient. Maybe, future Haskell language could apprehend some special construct, li

[Parsec] Extracting line and column numbers

2004-01-13 Thread Stefan Holdermans
Hi, I'm using the Parsec library to parse strings for a small experimental language. I'd like to decorate each node in the abstract syntax tree with a pair (Int, Int) that represents the line and column number in the strings. Unfortunately, the SourcePos class in the Parsec library is abstract and

Preliminary CFP: DALT 2004 - 2nd Workshop on Declarative Agent Languages and Technologies

2004-01-13 Thread João Leite
- P R E L I M I N A R Y C A L L F O R P A P E R S The Second International Workshop on Declarative Agent Languages and Technologies (DALT-2004) http://centria.di.fct.unl.pt/~jleite/dalt04/index.htm to b

Call for papers: Fourth International Workshop on Reduction Strategies in Rewriting and Programming (WRS'04)

2004-01-13 Thread Sergio Antoy
=== We apologize for multiple copies of this call for participation === * *

RE: GHC, functional dependency, rank-2 type

2004-01-13 Thread Simon Peyton-Jones
That is indeed bizarre. I'll look into it. Simon | -Original Message- | From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of | [EMAIL PROTECTED] | Sent: 13 January 2004 05:51 | To: [EMAIL PROTECTED] | Subject: GHC, functional dependency, rank-2 type | | | There appears to be