Re: De facto Haskell 2000?

2000-01-21 Thread Lennart Augustsson

Jan de Wit wrote:

> I'm under the impression that Hugs has the most features (probably because
> it's relatively easy to hack on, being an interpreter in C), GHC comes next
> after that and tends to adopt features introduced in Hugs, and NHC and HBC
> lag far behind that (no compiler wars please - each tool has its strength
> and weaknesses and its niche).

I must jump to the defense of HBC here.  It had existential quantification years
before the others, and universal around the same time as GHC.  It's just that
GHC/Hugs happened to pick a different syntax.
It also depends on which features you want.  If you, e.g., want views than only
HBC has it.

   -- Lennart





Re: `partition', laziness policy

2000-01-21 Thread Fergus Henderson

On 20-Jan-2000, S.D.Mechveliani <[EMAIL PROTECTED]> wrote:
> The questions are:
> 
> (1) What laziness freedom is allowed for a Standard function
> implementation?

I think the answer to that is "none".
Implementations are free to optimize code, so long as the
operational semantics that they implement correctly reflects
the source code's denotational semantics.  But the denotational
semantics specifies exactly which expressions may evaluate
to bottom (i.e. may return a runtime error or loop), so changing
a function to make it more or less lazy is not allowed.

> (2) Should Haskell consider also the stronger equivalence relation
> on programs?

Opinions on this differ.

But if you're looking for a declarative language which does take
this approach, the only one that I know of is Mercury.
In Mercury, the declarative semantics do not specify when a
procedure can throw an exception or fail to terminate.
That is considered part of the operational semantics.
There is a standard "strict sequential" operational semantics,
and compilers are required to provide a mode which implements
that, but they are also allowed to provide modes which implement
operational semantics which are lazier than the strict sequential
operational semantics.

-- 
Fergus Henderson <[EMAIL PROTECTED]>  |  "I have always known that the pursuit
WWW:   |  of excellence is a lethal habit"
PGP: finger [EMAIL PROTECTED]| -- the last words of T. S. Garp.



De facto Haskell 2000?

2000-01-21 Thread Jan de Wit

Hi All,

Currently there are three and a half major Haskell 98 platforms: the
GHC/Hugs combo, NHC98 and HBC. All of these have some extensions to the
official language, as well as extra libraries. Every platform has
existential type quantification, GHC/Hugs has multi-parameter type classes,
universal quantification (maybe NHC has that too - I don't have the
documentation at hand), Hugs has support for records, functional
dependencies and implicit parameters. A veritable plethora of features!

When I'm coding in Hugs I have a tendency to use all those sexy features
because I find them very useful. However, whenever I think about producing a
compiled version for multiple platforms, it makes me be very cautious in
actually using them. Currently, whenever I have a nice Module.hs that uses
implicit parameters I rename it to ImplicitModule.hs and write a
NormalModule.hs that doesn't. But sometimes, e.g. when using universal
quantification, this isn't possible. Also this limits my choice of
libraries: Swierstra's error correcting parser library uses universal
quantification in an essential way and so I can't use it for NHC at all, or
for HBC without (superficial) syntax changes.

I'm under the impression that Hugs has the most features (probably because
it's relatively easy to hack on, being an interpreter in C), GHC comes next
after that and tends to adopt features introduced in Hugs, and NHC and HBC
lag far behind that (no compiler wars please - each tool has its strength
and weaknesses and its niche).

So will the features of Hugs eventually be supported by all platforms and
integrated into a future version of Haskell or will I have to keep seperate
versions of my code?

All the best,

Jan de Wit






Re: partition and lifted products

2000-01-21 Thread Mark Tullsen

Ross Paterson wrote:
> 
> On Wed, Jan 19, 2000 at 03:18:34PM -0700, Joe Fasel wrote:
> > *Sigh*  And the language named in honor of Haskell Curry
> > for which Currying is not a valid transformation strikes
> > again!
> 
> Worse, not only are the built-in product and function types lifted,
> but one can't define the unlifted ones.  Before Haskell 1.3, even though
> the built-in product was lifted, one could define pairs as an abstract
> type exporting functions to make pairs and extract their components,
> which would then behave as true products.  But then seq was introduced
> (and in Haskell 98 extended to type variables) so everything is lifted.
> 
> Can we have extensional products and functions (or at least the means
> to define them) please?

Just to add my vote: Yes, please give us these!  I'm working on a program
transformation system for a subset of Haskell.  But it's not really a
subset of Haskell, it has true products and functions.  This is because
to do without them means either that I have to jettison lots of laws and 
equivalences or that I have to transform using "partial correctness" 
---equivalence modulo termination---rather than "total correctness": yuck).

Most people I've talked to consider lifted products a mistake.  
(This may not mean that most consider it a mistake, maybe only that 
those who have disagreed have not bothered to tell me so.)
Numerous others are unaware that products are lifted in Haskell!  
A while back, I asked John Peterson about the history of lifted products
in Haskell.  He told me that the decision was based on pragmatics 
(not semantics or efficiency): that it was simpler for implementations
to represent an n-tuple as an n-ary constructor than to add an extra
construct to the language (am I quoting you correctly, John?).

- Mark Tullsen



Re: positive Num?

2000-01-21 Thread S.D.Mechveliani

Eileen Head  <[EMAIL PROTECTED]>  wrote

> Is there an easy way to define a new class, X, of types which is a
> class of some range of types in an existing class Y.
> [..]
> For example can you define a class PosNum in which the type in the
> class are positive Ints, positive Integers, positive Floats and
> positive Doubles?


If I am not misleading the direction, it is NOT possible.

Because such a class presumes to have the _instances_ which are the
proper subsets. For example, one should be able at least to define 
the type of positive integers, with the appropriate instances.
Positive Integer is a subdomain of Integer. And the mathematical 
constructors to create a new domain are much more powerful than the 
type constructors of Haskell.
In Haskell a new type is created only by applying constructor to
the parameter types. Say,  
  C Integer,  (Integer, [Integer]).
But it takes to a new type only the _whole_ set of values of the 
parameter types, one cannot make it a proper subset.
For example, the compiler would recognize in the above example of 
C Integer   that  ` C 'b' '  does not denote a correct value, and
that  `C 2'  is correct.  But it considers also  `C (-2)'  
as correct, and (-2) is not of Positive integer.
Hence, to define a subdomain is possible, maybe, only in some much
weaker sense.
For example, one may introduce   data PosInt = PosI Integer,
write an application which tests  n > 0  each time it sees any
PosI n.  One could define  +,-,negate ...  instances for it, so that  
negate (PolI n) --> error ...
This models positive integers to some extent, but this domain check 
is not supported by the Language, by compiler.


--
Sergey Mechveliani
[EMAIL PROTECTED]









program transformer announcement

2000-01-21 Thread S.D.Mechveliani

Dear haskellites,

Please, find enclosed the ANNOUNCEMENT from my colleague.
This is on the
   functional program transformer  
   (called supercompiler - scp).

The object language is Refal - certain typeless language for the 
recursive functions, based on the pattern matching.
You may also run Scp on-line and see, how it simplifies the programs.

--
Sergey Mechveliani
[EMAIL PROTECTED]



*
Scp4's news.

Dear colleagues.

I would like to inform you that now  a supercompiler can be seen in its job
from  any country. You are welcome to visit the next site:
http://www.botik.ru/pub/local/scp/refal5/ .

The supercompiler by Andrei Nemytykh and Valentin Turchin.

I'd like to draw your attentinon:
   -- There can  be a  traffic jam on Russian Web lines. In my opinion, the
best time
   to test  the supercompiler under the Web is from 01:00 a.m to 10:00
a.m. Moscow
   time.
   -- The server (where the supercompiler is installed ) can be very seldom
unreachable
   from 10:00 a.m.  to 17:00 a.m. Moscow time.

 I'll very grateful to you for any questions and remarks.

I must apologize to you if this information is not  interesting for you.

Sincerely,
Andrei Nemytykh.
[EMAIL PROTECTED]










Your site has been included on OpenHere

2000-01-21 Thread Sara

Hi,

Your site has been included in the OpenHere.com index and search engine.  OpenHere is 
one of the 10 largest index and search sites on the Internet.  

Your site listing is:
Link:  http://www.haskell.org/mailinglist.html
Title:  The Haskell Mailing List
Description:  


You might have already received a message similar to this one, as we send a note when 
ever we add a link to your site in a different category on OpenHere.com.

At OpenHere you can dynamically modify your site's listing at any time.  You can also 
include your site's listing in other categories on OpenHere.com.  

When you modify your site's listing, it is automatically placed at the top of the 
category in which it is included, and is placed first in the search engine results for 
the keywords relating to your site.

To modify, add or delete your listing:

1.  Go to the page on OpenHere where your site is presently listed or you would like 
it listed.
2.  Select "Suggest a Site".
3.  Follow the instructions for changing your listing.

All of the modifications you submit to OpenHere.com are processed in real time.  As 
soon as you see the response to your submission, your site listing should be updated.

www.OpenHere.com is frequented by both children and families.  As a result, 
www.OpenHere.com does not include links to material which is illegal to display to 
minors.

Sara
www.OpenHere.com
Your key to the Net!



Re: partition and lifted products

2000-01-21 Thread Ross Paterson

On Wed, Jan 19, 2000 at 03:18:34PM -0700, Joe Fasel wrote:
> *Sigh*  And the language named in honor of Haskell Curry
> for which Currying is not a valid transformation strikes
> again!

Worse, not only are the built-in product and function types lifted,
but one can't define the unlifted ones.  Before Haskell 1.3, even though
the built-in product was lifted, one could define pairs as an abstract
type exporting functions to make pairs and extract their components,
which would then behave as true products.  But then seq was introduced
(and in Haskell 98 extended to type variables) so everything is lifted.

Can we have extensional products and functions (or at least the means
to define them) please?



The LINEAR International Summer School

2000-01-21 Thread Nuno Barreiro

Please forward.
Best regards,
Nuno Barreiro

--




 The LINEAR International Summer School

 (Linear Logic and Applications)

 August 30 to September 7, 2000

Hotel Terra Nostra, S.Miguel, Azores, Portugal



The Linear TMR research network (http://iml.univ-mrs.fr/LINEAR) is
proud to announce its first International Summer School on Linear
Logic and Applications.

The school lasts one week and comprises both lectures and thematic
sessions directed to young computer scientists and mathematicians
interested in the field of formal logic and its applications.

The lectures are in the tradition of summer schools and cover one
topic, from basic material to more advanced issues. The topics and
lecturers are the following:

  Samson Abramsky --- Game Semantics
  Jean-Yves Girard -- Linear Logic and Ludics
  Stefano Guerrini -- Proof-Nets and Lambda-Calculus
  Yves Lafont --- Phase Semantics and Decision Problems
  Phil Scott  Category Theory and Concrete Models

The thematic sessions will cover state-of-the-art research in Linear
Logic. Each session has an organiser responsible for inviting speakers
who will talk about their work. The themes and organisers are the
following:

  Andrea Asperti  Applications
  Vincent Danos - Proof Theory
  Thomas Ehrhard  Semantics
  Glynn Winskel - Concurrency

The school will be held in the island of S.Miguel, Azores, amid
luxurious vegetation and hot water springs. The entrance to the mythic
kingdom of the Atlantis is believed to be located near Hotel Terra
Nostra, some say at the bottom of its famous red and hot water swimming
pool...

Mark the dates on your agenda now. Up-to-date information, including
the application form, is being made available at

  http://linear.di.fc.ul.pt

Don't forget to check it!